-
Notifications
You must be signed in to change notification settings - Fork 717
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
CJS build in v9.116.0 breaks Next.js projects (TypeError: a is not a function) #2198
Comments
I tried to render in vitest with a component for drei
|
I think it is the same issue we had previously when upgraded to rollup 3: #1570 @CodyJasonBennett can we find a fix and keep rollup4? Also, why the e2e tests didn't failed, do you know? Could be great to reproduce the issue in the e2e tests, so we don't face it again |
We need to revert the upgrade and ensure we have e2e tests that consume CJS before we retry. If we opt out of SSR in Next, then that skips CJS, for instance. |
merged > now releasing a patch version https://github.com/pmndrs/drei/releases/tag/v9.116.1 in few minutes @rossyman can you then test it is fixed? |
@CodyJasonBennett I will try adding a SSR e2e test for cjs EDIT: #2201 |
@CodyJasonBennett there is now a cjs e2e test that reproduces @rossyman 's error and makes the previous rollup4 commit fail https://github.com/pmndrs/drei/actions/runs/11877820543/job/33097749021?pr=2201#step:8:798 |
three
version: 0.170.0@react-three/fiber
version: 8.17.10@react-three/drei
version: 9.116.0node
version: 20.10.0npm
(oryarn
) version: 10.2.3 (Also on bun: 1.1.34)Problem description:
v9.116.0 CJS build breaks Next.js projects. Previously resolved in this discussion: #1544
Relevant code:
Seems to be zustand related code.
v9.115.0 build (Working):
v9.116.0 build (Broken):
Suggested solution:
Downgrade to v9.115.0
The text was updated successfully, but these errors were encountered: