React 18 support #31943
-
The React team has announced the Stable version of React 18. We're part of the working groups and are adopting new features, one by one. How to useInstall Your feedbackWe're very much looking for feedback from you using React 18 and its new features. We'll expand this section with more asks and details in the future, but for now, our specific asks would be:
NotesYou're now able to use new functionality like Check out our React 18 e-commerce demo, the code lives at https://github.com/gatsbyjs/react-18-ecommerce-demo |
Beta Was this translation helpful? Give feedback.
Replies: 10 comments 49 replies
-
Beta Was this translation helpful? Give feedback.
-
Another question will be, with React 18, is it possible to pre-render/SSR the entire page so that the page will have all the barebone HTML elements by default. Then, when it comes to re-hydration, it "Selective Hydrate", prioritizing those sections (wrapped in Currently, when using |
Beta Was this translation helpful? Give feedback.
-
So I notice there is a release on npm named Does anyone know what is going on? I'm confused. |
Beta Was this translation helpful? Give feedback.
-
So after using Edit: It does seem to relate to |
Beta Was this translation helpful? Give feedback.
-
Just wanted to chime in with another potential issue: Using
Minimal repro here: Page Page Navigating using gatsby-link from Page Downgrading to React 17 causes the runtime errors to go away on `, but the images still "flicker" when swiped through on the art directed carousel (the non art directed carousel doesn't flicker). Gatsby Info dump:
|
Beta Was this translation helpful? Give feedback.
-
I was on
with Gatsby version:
and it is working fine, except some minor hydration errors I just tried with:
And got the same message as ardiewen (#31943 (comment)) Are there any news for React beta v18 compatibility with Gatsby v3 or v4? Thanks a lot, Phil |
Beta Was this translation helpful? Give feedback.
-
Hi @wardpeet and Gatsby team, we also started a minimal project and got the same error, This happens with no flags, and using the latest releases as of today, Our team is very interested in helping you get this off the ground, as our sites tend to be CPU-heavy despite existing optimization options, so we're hungry for the new Transition API. We do use Netlify CMS and rely heavily on Any progress report on this front? And thanks for the effort to break this ground! |
Beta Was this translation helpful? Give feedback.
-
We are currently currently using React 18 for SSR with We have tried upgrading multiple times to Gatsby 4.X but have run into issues every time. It seems that Gatsby 4 doesn't support React 18, and we are therefore stuck on Gatsby 3.14. Is there any plan to continue React 18 support? |
Beta Was this translation helpful? Give feedback.
-
Hi all, as of the recent release of gatsby 4.11 we have 100% compatibility with React 18 again. I encourage you to test it out and share feedback here with your experience. |
Beta Was this translation helpful? Give feedback.
-
After updating to 4.11 and bumping react to 18, I'm getting these |
Beta Was this translation helpful? Give feedback.
Hi all, as of the recent release of gatsby 4.11 we have 100% compatibility with React 18 again. I encourage you to test it out and share feedback here with your experience.