-
Notifications
You must be signed in to change notification settings - Fork 86
fix: remove Next.js as a peer dependency #1584
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
Conversation
was leading to wrong version of next.js being bundled in with functions. specifically, a newer version next would be installed when the project uses an older (and at times incompatible with the newer) versoin
✅ Deploy Preview for netlify-plugin-nextjs-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for next-hp-edge-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for netlify-plugin-nextjs-static-root-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for netlify-plugin-nextjs-nx-monorepo-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for next-plugin-rsc-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for next-i18next-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for netlify-plugin-nextjs-next-auth-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for next-plugin-canary ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for netlify-plugin-nextjs-export-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for next-plugin-edge-middleware ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
✅ Deploy Preview for nextjs-plugin-custom-routes-demo ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This makes sense based on the issue @danez reported and folks will always have Next installed since the runtime is for Next. 😎
This is why I thought it would be safe to have it as a peer dep. |
In that case adding it as dev dependency would work. As our ci only installs production dependencies. |
Summary
Removes Next.js as a peer dependency within the runtime package as at times it was leading to multiple version of Next.js being installed, and incompatible versions being bundled with the functions when the project was using an older version.
Test plan
Deploy preview: https://ep-next-test.netlify.app/
The https://ep-next-test.netlify.app/api/hello route is an SSR route
Test case provided in issue: https://ep-hbo-clone.netlify.app/movie (this should render correctly, no error)
Relevant links (GitHub issues, Notion docs, etc.) or a picture of cute animal
Fixes https://github.com/netlify/pod-ecosystem-frameworks/issues/220