-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add example for Next.js #5108
Add example for Next.js #5108
Conversation
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.
Requesting changes in blanco
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.
🚀
FYI – the optimal setup for Next.js / web to confirm tree shaking would be to get rid of |
@nandorojo I am currently working on that in #5203 |
Awesome, glad to see this getting attention. Just left some comments. |
Summary
This PR adds an example with Next.js and a CI to test build fails. It is intended to prevent using api that is only available in a browser (w.g. window) without an appropriate check. This ensures that reanimated can be used with SSG.
Test plan
Build the example with
yarn build
and start withyarn start
. You can also start it in dev mode usingyarn dev
and check if it responds changes in reanimated core.