We want to start a new project . We did POC for about a month on choice of frameworks. We chose React for building our application. So what is the plan on officially releasing React-fiber because we dont want to be doomed.
We are in the same boat. We would love to have a more specific date so we know where we stand.
We're also waiting for it. And react-fiber will not be optional right? 16. version of react will be fiber? am i right?
You all can start with 15.5 release. There won't be notable breaking changes in API except async setState. You just need to follow recomentation about it.
Hey!
I wonder if thereās any specific place these concerns are coming from? If thereās a blog post raising panic weād like to know š
And react-fiber will not be optional right? 16. version of react will be fiber?
Yes, React 16 is using Fiber, but in a compatibility mode. All async features are disabled for better compatibility.
There won't be notable breaking changes in API except async setState.
This is incorrect by the way. React 16 operates in compatibility mode. There are no changes to setState
in it.
So what is the plan on officially releasing React-fiber because we dont want to be doomed.
Fiber is not a new React API. The internals have changed, but the API stays the same. There are virtually no breaking changes in React 16 associated with Fiber itself.
We do have some breaking changes in React 16 (such as moving createClass
to another package). They are completely unrelated to Fiber, and are part of our regular deprecation cycle. As described in the 15.5.0 blog post, we provide automatic scripts (ācodemodsā) to update your code from deprecating APIs, and give you time to migrate. If you donāt see any warnings when using 15.x, it means your code is ready for React 16 when it comes out.
So what is the plan on officially releasing React-fiber because we dont want to be doomed.
You wonāt be ādoomedā. If Fiber works out of the box for 30,000 existing components in Facebook codebase, it will likely work for your codebase too. š Start with React 15, fix deprecation warnings if you see any (or wait for third party components to fix them), and when youāre ready, jump ahead to React 16, and your app will just work.
We would love to have a more specific date so we know where we stand.
There is no specific date. It is likely going to be released this summer but we donāt know exactly. But there is no point in waiting for it, just like there was no point in waiting for React 0.14, or React 15. This is just a regular version update, and it works the same way as before.
Further reading:
Hope this addresses your concerns!
As far as I can tell, using React since 0.5.2, the core API has always been very stable because the underlying principles remained the same over time.
Except few breaking changes mostly due to language evolutions (like createClass/mixins => ES6 class) you can probably start at React n and migrate to React n+3 without too much pain. I expect this to remain true in the future as well. Bonus: codemods are provided to help so sometimes a migration can be done in 5 minutes.
I can attest to that. I've been using React for almost two years and there has never been a breaking change. Old features are deprecated in the next release but continue to work, and then removed in next+1 release (which is usually at least 6 months later). So you can always upgrade to latest version and have a couple of months to gradually update your code (which is relatively simple thanks to codemods and warnings that tell you exactly what to change).
Compare that, for example, with Angular where major releases require you to update your entire app at once (or be stuck with the old version).
Question @gaearon,
Yes, React 16 is using Fiber, but in a compatibility mode. All async features are disabled for better compatibility.
Will there be a way to enable async features for even more forward leaning codebases, or are they/their documentation incomplete for React 16?
Will there be a way to enable async features for even more forward leaning codebases
We are still figuring it out for our own codebases. There will likely be some unstable API, you can track https://github.com/facebook/react/pull/9448 for the discussion.
As of now, there are known bugs in async mode.
Most helpful comment
Hey!
I wonder if thereās any specific place these concerns are coming from? If thereās a blog post raising panic weād like to know š
Yes, React 16 is using Fiber, but in a compatibility mode. All async features are disabled for better compatibility.
This is incorrect by the way. React 16 operates in compatibility mode. There are no changes to
setState
in it.Fiber is not a new React API. The internals have changed, but the API stays the same. There are virtually no breaking changes in React 16 associated with Fiber itself.
We do have some breaking changes in React 16 (such as moving
createClass
to another package). They are completely unrelated to Fiber, and are part of our regular deprecation cycle. As described in the 15.5.0 blog post, we provide automatic scripts (ācodemodsā) to update your code from deprecating APIs, and give you time to migrate. If you donāt see any warnings when using 15.x, it means your code is ready for React 16 when it comes out.You wonāt be ādoomedā. If Fiber works out of the box for 30,000 existing components in Facebook codebase, it will likely work for your codebase too. š Start with React 15, fix deprecation warnings if you see any (or wait for third party components to fix them), and when youāre ready, jump ahead to React 16, and your app will just work.
There is no specific date. It is likely going to be released this summer but we donāt know exactly. But there is no point in waiting for it, just like there was no point in waiting for React 0.14, or React 15. This is just a regular version update, and it works the same way as before.
Further reading:
Hope this addresses your concerns!