Make import of ReactDOMServer work with React 18#66
Conversation
|
Hi @fsoikin, any news? Just brainstorming for the error cause:
build:
strategy:
matrix:
react-version: [16, 17, 18]
|
|
No, I haven't had much time to work on this one. It's not required for my current day job, so I can't justify spending too much effort. React 18 is sure incompatible with 17, but I don't see how that makes any difference here. We're not trying to use them side by side, only swap one for the other. React 18 seems to have a slightly different module organization, which doesn't allow the same code to import both server-side and client-side modules, but I haven't really investigated in depth. If you have any ideas and free time, feel free to try this yourself, I will very much appreciate a contribution. (and yes, that's a typo; fixed; but it's not the exact error message, I was just paraphrasing anyway) |
Importing
react-dom/server.jsworks with React 16 and 17, but for some reason fails with React 18.esbuildreports that "react-dom does not export server.js".