Issue with nextjs using flowbite tailwind css #37004
Replies: 3 comments 1 reply
-
|
Hi, You need to do Do you have any code to share? There must be a function from Flowbite that's trying to access the window during SSR. Usually there's a flag one must pass, or the framework does the check internally. If you share some code I can help you debug, or find info on Flowbite's docs to help you. EDITLooks like it is a known issue, and not very trivial after all, themesberg/flowbite#51. |
Beta Was this translation helpful? Give feedback.
-
|
Use useEffect for to fix this issue In pages/_app.tsx useEffect(() => { Or complete solution, follow the step below: |
Beta Was this translation helpful? Give feedback.
-
|
use the Next page component on each file you are using
and extend at every component file you are using
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Please help: getting this issue "ReferenceError: window is not defined" for Nextjs with import flowbite
npm: '8.5.5',
node: '16.15.0',
Next.js v12.1.5
Beta Was this translation helpful? Give feedback.
All reactions