Getting an Error with SSR after most recent update
See original GitHub issueAfter the most recent update I’m getting this error:
regeneratorRuntime is not defined
ReferenceError: regeneratorRuntime is not defined
at /sandbox/node_modules/@react-spring/core/index.cjs.js:635:5
at /sandbox/node_modules/@react-spring/core/index.cjs.js:687:4
at Object.<anonymous> (/sandbox/node_modules/@react-spring/core/index.cjs.js:1203:2)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Module.require (internal/modules/cjs/loader.js:690:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (/sandbox/node_modules/@react-spring/web/index.cjs.js:8:12)
at Module._compile (internal/modules/cjs/loader.js:776:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
Here is a fresh codesandbox and it happens with Nextjs in just a vanilla example. https://codesandbox.io/embed/hello-world-49rmf
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Enable Angular 13: SSR error with Webpack - Stack Overflow
I was wondering if this have anything to do with webpack and I found that there has been some questions that has been...
Read more >Create a custom error component in Next.js (SSR & CSR)
First, create a fresh Next.js project by running npx create-next-app@latest custom-error-component · stop npm in your terminal and run npm run ...
Read more >Debugging and fixing hydration issues - somewhat abstract
Spotting hydration errors and fixing them can prevent serious user-facing performance issues, and since we do not get a signal during ...
Read more >react-hydration-error - Next.js
When css-in-js libraries are not set up for pre-rendering (SSR/SSG) it will often lead to a hydration mismatch. In general this means the...
Read more >SSR 6.0 Release Notes | SSN Docs
If you do not see an issue listed below, it may have been resolved in another recently released version. A link to the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I found a workaround for this issue:
add
@babel/plugin-transform-runtime
as a dev dependency, and import it in your _app.js file:import 'regenerator-runtime/runtime';
https://babeljs.io/docs/en/babel-polyfill
Can confirm works! I guess issue is coming from
react-spring
using 9.x if you lock version atreact-spring@8.0.27
also worked for me