Menu TechCrunch Search
  • Follow Us
  • Facebook
  • Instagram
  • Twitter
  • Youtube
  • Flipboard
  • LinkedIn
  • Google+
  • RSS
  • More
    • Youtube
    • Flipboard
    • LinkedIn
    • Google+
    • RSS
Got a tip? Let us know.
  • News
    • Channels
      • Startups
      • Mobile
      • Gadgets
      • Enterprise
      • Social
      • Europe
      • Asia
      • Crunch Network
      • Unicorn Leaderboard
      • Gift Guides
    All Topics All Galleries All Timelines
  • Video
    Shows
      • Apps
      • Bullish
      • Crunch Report
      • News
      • Gadgets
      • Reviews
      • Interviews
      • TC Features
    All Shows
    All Videos
  • Events
    • TechCrunch Events
      • Disrupt
      • Startup Battlefield
      • Crunchies
      • Meetups
      • International City Events
      • Hackathon
      • Sessions
      • Include
      • TechCrunch Store
    • News About
      • Mobile World Congress
      • CES
    All Events
  • Crunchbase
  • Trending
  • Facebook
  • Tesla
  • Snap
  • News
  • Startups
  • Mobile
  • Gadgets
  • Enterprise
  • Social
  • Europe
Search TechCrunch

Hi!

You are about to activate our Facebook Messenger news bot. Once subscribed, the bot will send you a digest of trending stories once a day. You can also customize the types of stories it sends you.

Click on the button below to subscribe and wait for a new Facebook message from the TC Messenger news bot.

Thanks,
TC Team

Disrupt NYThe Action-Packed Agenda For Disrupt NY Is Live See Who's Coming To Disrupt

F8 2017

April 18 - 19, 2017

  • Coverage
Developer
  • Facebook expands its open-source portfolio with new UI framework for Android

    Facebook expands its open-source portfolio with new UI framework for Android

  • Facebook launches React VR, a new JavaScript framework for building basic VR apps

    Facebook launches React VR, a new JavaScript framework for building basic VR apps

  • Facebook updates Messenger with support for QR codes, food delivery through M and more

    Facebook updates Messenger with support for QR codes, food delivery through M and more

  • Browse more...

Facebook
  • Facebook expands its open-source portfolio with new UI framework for Android

    Facebook expands its open-source portfolio with new UI framework for Android

  • Mark Zuckerberg speaks out about Cleveland shooting

    Mark Zuckerberg speaks out about Cleveland shooting

  • Facebook updates Messenger with support for QR codes, food delivery through M and more

    Facebook updates Messenger with support for QR codes, food delivery through M and more

  • Browse more...

Javascript
  • Facebook partners with Google, others to launch a new JavaScript package manager

    Facebook partners with Google, others to launch a new JavaScript package manager

  • Microsoft says its Edge browser is still more energy-efficient than its competitors

    Microsoft says its Edge browser is still more energy-efficient than its competitors

  • Facebook’s new open source project makes it easier to get started with React

    Facebook’s new open source project makes it easier to get started with React

  • Browse more...

developers
  • Twitter unveils a new API platform, roadmap and vision for its developer community

    Twitter unveils a new API platform, roadmap and vision for its developer community

  • Amazon Alexa developers can now ask for customer’s location, track their skills’ performance

    Amazon Alexa developers can now ask for customer’s location, track their skills’ performance

  • Cloud Foundry launches its developer certification program

    Cloud Foundry launches its developer certification program

  • Browse more...

Facebook announces React Fiber, a rewrite of its React framework

Posted 5 hours ago by Frederic Lardinois (@fredericl)
  • 0

    SHARES
Next Story

Apple makes iWork, iMovie & GarageBand apps free to all Mac & iOS users

Facebook has completely rewritten React, its popular JavaScript library for building user interfaces. The company hasn’t previously talked much about React Fiber, as the project is called, but it has actually been working on it for a while. It’s now ready to talk about this project publicly in more detail (after word about it started spreading last year) and the plan is to put this rewrite into the hands of developers once React 16.0 launches later this year. It’s already in use on Facebook.com today, which clearly indicates that Facebook itself thinks it’s ready for prime time.

In addition, it is also launching a rewrite of Relay, its framework for building data-heavy applications.

React Fiber

The idea behind React Fiber, the company tells me, is to take what the company has learned from developing React the first time around and put that into an updated framework that is still fully backwards compatible with existing React-based applications. React Fiber, Facebook tells me, will become the foundation of any future improvements and feature development of the React framework.

The main focus here was to make React as responsive as possible, Facebook engineer — and member of the React core team — Ben Alpert told me in an interview earlier this week. “When we develop React, we’re always looking to see how we can help developers build high-quality apps quicker,” he noted. “We want to make it easier to make apps that perform very well and make them responsive.”

In light of this theme, it’s no surprise that the highlights of this new release are built-in primitives for scheduling and incremental rendering. “We want to make sure we render the right stuff at the right time,” Alpert said, and added that “responsiveness was a huge push here.”

But why rewrite React from scratch? “It was not necessarily that the old code base was bad, but we wanted to start with a new foundation that could power everything we do going forward,” Alpert said. That means the new code was developed from the ground up to be extensible, for example.

Alpert stressed that React Fiber will be backward compatible, though as with all major React updates, there will be a few small breaking changes. The team says it doesn’t anticipate that these will be problematic for developers, though. “We always had a strong API contract, so that gives us the flexibility to reimplement,” he added.

Relay Modern

As Facebook also today announced, Relay — the company’s JavaScript framework for building data-driven applications — has also been rewritten with a similar emphasis on performance and extensibility. Relay combines React with Facebook’s GraphQL query language and now Relay Modern, as the company calls this rewrite, is meant to push this concept further and overcome some of the limitations of the original design. That also meant simplifying some of the design to enhance the overall performance of the framework. “Relay Modern retains the best parts of Relay — colocated data and view definitions, declarative data fetching — while also simplifying the API, adding features, improving performance, and reducing the size of the framework,” the team explains in today’s announcement. To do this, the team implemented a number of changes, but most importantly, it adopted static queries and ahead-of-time optimizations.

Static queries essentially ensure that complex queries that aren’t altered by runtime conditions can be pre-built and offloaded to Facebook’s servers. So instead of sending complex queries across the network, all an application has to send is a string that identifies the pre-set query and the variables needed to complete it. Related to this, the ahead-of-time optimization feature in the Relay compiler now looks at the query structure to optimize the query that is now stored on the server to execute it faster — and hence return results to the user faster, too. Other new features in React Modern include built-in garbage collection, for example.

For developers who are already using an older version of Relay, Relay Modern comes with a compatibility API.

Facebook says that when its teams switched the Marketplace tab in the Facebook app from Relay to Relay Modern, the time to interaction on Android improved by an average of 900ms. While that doesn’t sound like much, every second on mobile counts, and that’s enough to make an application feel noticeably more responsive than before.

  • 0

    SHARES
Advertisement
Advertisement

Crunchbase

  • React

    • Description React is a JavaScript library for creating user interfaces by Facebook and Instagram.
    • Website https://code.facebook.com/projects/176988925806765/react/
    • Full profile for React

Newsletter Subscriptions

SEE ALL NEWSLETTERS »

Latest Crunch Report

  • Uber Might Have To Support Tips | Crunch Report

    Uber Might Have To Support Tips | Crunch Report

Watch More Episodes
  • Javascript
  • Facebook
  • developers
  • Developer
  • Popular Posts

Featured Stories

  • Facebook announces React Fiber, a rewrite of its React framework

    Facebook's F8 keynote recap

    VIDEO | 2:28 | News
  • Audi’s latest concept is a new all-electric Tesla Model X competitor

    Audi’s latest concept is a new all-electric Tesla Model X competitor

    5 hours ago | Darrell Etherington
  • Zuck says copying Snapchat was just step 1 of Facebook’s AR platform

    Zuck says copying Snapchat was just step 1 of Facebook’s AR platform

    7 hours ago | Josh Constine
  • Facebook launches augmented reality Camera Effects developer platform

    Facebook launches augmented reality Camera Effects developer platform

    7 hours ago | Josh Constine
  • Announcing the TechCrunch Disrupt NY 2017 agenda

    Announcing the TechCrunch Disrupt NY 2017 agenda

    8 hours ago | Matthew Panzarino, Chrystine L. Villarreal

Latest From TechCrunch

  • Facebook open sources Caffe2, its flexible deep learning framework of choice

    Facebook open sources Caffe2, its flexible deep learning framework of choice

    17 minutes ago | John Mannes
  • Crunch Report | Facebook Launches Camera Effects Platform

    Crunch Report | Facebook Launches Camera Effects Platform

    30 minutes ago | Anthony Ha
  • Oracle acquires ad measurement company Moat

    Oracle acquires ad measurement company Moat

    1 hour ago | Anthony Ha
  • StarCraft is now free, nearly 20 years after its release

    StarCraft is now free, nearly 20 years after its release

    2 hours ago | Greg Kumparak
Comment moderation powered by BrandBastion
Up Next

Apple makes iWork, iMovie & GarageBand apps free to all Mac & iOS users

Posted 5 hours ago

CrunchBoard

Job Listings

  • DevOps. Engineer (Linux) at W.W. Norton (New York, NY, United States)

  • Senior Software Engineer at Patientco (Atlanta)

  • Senior Software Development Engineer @ Microsoft at Microsoft (San Francisco, CA, United States)

  • Sr. Security Engineer at Moat (New York )

  • Product Manager at Moat (New York )

More from CrunchBoard
Advertisement

TechCrunch

  • News
  • Video
  • Events
  • Crunchbase
  • TechCrunch Store

About

  • Staff
  • Contact Us
  • Advertise With Us
  • Event & Editorial Calendar
  • Send Us A Tip
  • Activations Blog

International

  • China
  • Europe
  • Japan

Follow TechCrunch

  • Facebook
  • Twitter
  • Google+
  • LinkedIn
  • Youtube
  • Pinterest
  • Tumblr
  • Instagram
  • StumbleUpon
  • Feed

TechCrunch Apps

  • iOS
  • Android
  • Windows 8

Subscribe to The Daily Crunch

Latest headlines delivered to you daily

Subscribe to <span class="no-mobile">Subscribe to </span>The Daily Crunch
© 2013-2017 AOL Inc. All rights reserved. Aol Tech Privacy Policy About Our Ads Anti Harassment Policy Terms of Service
Powered by WordPress.com VIP
Fonts by <Webtype>
  • TechCrunch
    • News
      • Startups
      • Mobile
      • Gadgets
      • Enterprise
      • Social
      • Europe
      • Asia
      • Crunch Network
      • Unicorn Leaderboard
      • Gift Guides
      • All Galleries
      • All Timelines
    • Videos
      • Apps
      • Bullish
      • Crunch Report
      • News
      • All Shows
      • All Videos
    • Events
      • Disrupt
      • Startup Battlefield
      • Crunchies
      • Meetups
      • International City Events
      • Hackathon
      • Sessions
      • Include
      • TechCrunch Store
      • All Events
  • Crunchbase
Message Us
Most Popular
Facebook open sources Caffe2, its flexible deep learning framework of choice
17 minutes ago by John Mannes
Crunch Report | Facebook Launches Camera Effects Platform
30 minutes ago by Anthony Ha
Oracle acquires ad measurement company Moat
1 hour ago by Anthony Ha
StarCraft is now free, nearly 20 years after its release
2 hours ago by Greg Kumparak
Kickstarter launches a ‘request for projects’ program
3 hours ago by Haje Jan Kamps
HTC has a strange little bundle deal going for its pricey Vive VR headset
4 hours ago by Lucas Matney
Volkswagen’s I.D. CROZZ electric concept aims for 2020 production
4 hours ago by Darrell Etherington
Game over, man! The NES Classic is discontinued planet-wide
4 hours ago by Devin Coldewey
Facebook expands its open-source portfolio with new UI framework for Android
4 hours ago by Frederic Lardinois
Facebook launches React VR, a new JavaScript framework for building basic VR apps
5 hours ago by Frederic Lardinois