Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SSR not working in NextJS 13 and later versions. #425

Open
rawatmanoj opened this issue Jan 16, 2024 · 6 comments
Open

SSR not working in NextJS 13 and later versions. #425

rawatmanoj opened this issue Jan 16, 2024 · 6 comments

Comments

@rawatmanoj
Copy link

Library is not working without giving "use client" at the top. Even for SSR we have to give "use client" which makes it render client side.

@reekrd
Copy link

reekrd commented Jan 18, 2024

Same in NextJS 14. If the Carousel is imported in a component that does not define "use client" the following error is generated at compile time. Should be noted that this is for a project that uses the App Router

⨯ node_modules/react-multi-carousel/lib/types.js (1:262) @ d
⨯ TypeError: Object prototype may only be an Object or null: undefined
at setPrototypeOf ()
at extendStatics (webpack-internal:///(rsc)/./node_modules/react-multi-carousel/lib/types.js:10:11)
at eval (webpack-internal:///(rsc)/./node_modules/react-multi-carousel/lib/types.js:16:9)
at eval (webpack-internal:///(rsc)/./node_modules/react-multi-carousel/lib/types.js:31:12)
at eval (webpack-internal:///(rsc)/./node_modules/react-multi-carousel/lib/types.js:32:2)
at (rsc)/./node_modules/react-multi-carousel/lib/types.js

@RuiQiHuang1832
Copy link

+1 getting the same issue. On Version 13.5

@crosskpixel
Copy link

Change your file .tsx to .jsx Works for me

@metrorailings
Copy link

Same exact issue here. SSR is impossible on NextJS until this is fixed.

@LiamWinterton
Copy link

Having the exact same issue.

Abandoning this library in favour of something that doesn't have 5 year old examples in a fast paced world.

@ChetSocio
Copy link

What about using it as component and importing it on page.tsx file ? It works fine on my side but i have z-index issue and scroll is not smooth and not quiet responsive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants