React for SSR & preact just in the browser? #3537
kurtextrem
started this conversation in
General
Replies: 1 comment
-
This should work, but it's not something we officially support. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Has anyone tried using React for SSR (e.g. v18) & preact just in the browser (so only the hydration + adding event listeners)?
I'm not sure if this frankenstein approach is feasible, but since preact is smaller and faster in hydrating, this might be worth exploring, while having 'full' compatibility with React 18 on the server-side. This would mean for server code, webpack or other bundlers would not alias react-dom/react and for the client bundle it would.
Beta Was this translation helpful? Give feedback.
All reactions