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

Make Provider a server component #23

Open
shuding opened this issue Jan 7, 2023 · 1 comment · May be fixed by #36
Open

Make Provider a server component #23

shuding opened this issue Jan 7, 2023 · 1 comment · May be fixed by #36
Assignees

Comments

@shuding
Copy link
Owner

shuding commented Jan 7, 2023

It's not needed to include the script content in the client bundle and hydrate <Provider> if you import it from a server component.

@shuding shuding self-assigned this Jan 7, 2023
@awndrw awndrw linked a pull request Jan 23, 2023 that will close this issue
@firxworx
Copy link

firxworx commented Aug 9, 2023

My $0.02 as a random passer-by who recently learned about this library is that react-wrap-balancer should not exclusively depend on server-side functionality...

If there is a server/client option I think a client-only/SPA-friendly version should still be available + viable.

I doubt I'm the only one who has dropped this neat package into client-side only scenarios (e.g. React + Vite) for an immediate aesthetic improvement.

As-is the current version seems to break with static generator setups.

Currently I have no issues with React + Vite building into SPA's. However I just discovered this library is the sole cause of a broken production build of an Astro + React project generating static documentation that I'm working on.

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 a pull request may close this issue.

2 participants