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

🧑‍💻add 'use client' to relevant index files #3716

Closed
wants to merge 2 commits into from

Conversation

oddvernes
Copy link
Collaborator

resolves #3702

it was reported that 'use client' on the main index file did not "inherit" down to sub-components. This pr adds 'use client' to the index of components with sub-components. I don't have a test setup to check if this works so I'll make a dev release for @sebastianvitterso to check

Copy link
Collaborator

@torleifhalseth torleifhalseth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@oddvernes
Copy link
Collaborator Author

This did not work, we'll leave this for a bit while @sebastianvitterso does some more research

@sebastianvitterso
Copy link
Contributor

I opened an issue in the Nextjs repo vercel/next.js#74585 so they can help. Seems to be a very strange edge-case we're hitting here.

@oddvernes
Copy link
Collaborator Author

For reference, @sebastianvitterso found this article explaining the issue at hand. So to fully support ssr we would need to either change to the pattern descibed in this article (big breaking change) or make the subcomponents available for import individually (maybe ideally imported from a sub-path and not root directly to avoid chaos)

@oddvernes oddvernes closed this Jan 10, 2025
@oddvernes oddvernes deleted the OOVE/3702-use-client-fix branch January 10, 2025 12:36
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

Successfully merging this pull request may close these issues.

feat: support next.js out-of-the-box
3 participants