The requested module 'react' does not provide an export named 'useLayoutEffect' #1606
Replies: 6 comments 3 replies
-
I'm also getting this error for a popover when I upgraded from 1.4.1 to 1.6.5 |
Beta Was this translation helpful? Give feedback.
-
I'm only getting this when deploying to Cloudflare pages. I think the logs might have some clues to someone who knows what they're looking for. Likely an environment issue, right?
|
Beta Was this translation helpful? Give feedback.
-
also experiencing. installing @headlessui/react@insider, removing the .next folder, or reinstalling all dependencies didn't fix it, @RobinMalfait |
Beta Was this translation helpful? Give feedback.
-
I have the same error, did anyone find a workaround? |
Beta Was this translation helpful? Give feedback.
-
I resolved this problem on CloudFlare Pages. Their build system is currently using node 12 by default which seems to cause this issue, but you can have Cloudflare use a newer node version by setting the environmental variable I believe you can do something similar on Netlify as well. |
Beta Was this translation helpful? Give feedback.
-
Hey, I also had this issue (locally) after a fresh install of one of the tailwind templates! For me, removing the .next folder, using insiders, and reinstalling dependancies didn't work. After upgrading my node version I was good to go, on my first install I was using node 14 and upgraded at 19.2.0 and everything worked as expected :) |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi i am using headles ui
with "next": "12.1.6", "react": "18.1.0", "react-dom": "18.1.0",
Server Error
SyntaxError: The requested module 'react' does not provide an export named 'useLayoutEffect'
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: false,
};
module.exports = nextConfig;
everything is fine but i don't know why this error is come when i reomove headles ui components then working fine but when use headles component error is come?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions