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

Support server bundling with vite #21

Closed
dai-shi opened this issue Apr 15, 2023 · 4 comments · Fixed by #36
Closed

Support server bundling with vite #21

dai-shi opened this issue Apr 15, 2023 · 4 comments · Fixed by #36

Comments

@dai-shi
Copy link
Owner

dai-shi commented Apr 15, 2023

Currently, wakuwork uses react-server-dom-webpack/node-loader for handing "use client" and "use server".
We use vite for client bundling, but for server bundling we use a naive approach.
It's limited. For example, we now don't support "use client" in node_modules.

I'm hoping we could use vite for server bundling. Wish vite-rsc does that.

@nksaraf What's the current status?

@dai-shi
Copy link
Owner Author

dai-shi commented May 5, 2023

I will see if I can do it in this repo.

@dai-shi dai-shi changed the title Use vite-rsc? Support server bundling with vite May 5, 2023
@hyf0
Copy link
Contributor

hyf0 commented May 9, 2023

Have you thought through it?

I guess we just need to adapt the register logic in Rollup and apply it for use client components in transform hook.

@dai-shi
Copy link
Owner Author

dai-shi commented May 9, 2023

Well, I'm learning vite. Will open a PR if something is ready.

@dai-shi
Copy link
Owner Author

dai-shi commented May 11, 2023

Having a trouble...

(It's worked around.)

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