Replies: 5 comments 2 replies
-
For something to compare to, you can see that next only conditionally polyfills fetch. |
Beta Was this translation helpful? Give feedback.
-
I'm curious about this as well, because I'm actually running into issues that appear to be caused by the polyfills. The open PRs and issues about the custom polyfills also have been unresolved for a long time. For example, I'm unable to use |
Beta Was this translation helpful? Give feedback.
-
I created a PR to implement this: #6259 |
Beta Was this translation helpful? Give feedback.
-
We just published version |
Beta Was this translation helpful? Give feedback.
-
Undici is still broken on 1.17.1 (edit: looks like in general Remix isn't ready for Node 18/20)
|
Beta Was this translation helpful? Give feedback.
-
Hi. I'm trying to convert a project to remix for the first time. Everything's going pretty well so far, but one thing about remix's node runtime has stood out to me: the web API polyfills. Things like fetch, FormData, the web streams API, etc.
Modern nodes provide implementations of every web API remix polyfills on the global object, but remix unconditionally sets its polyfills on the global object, blowing the native implementations away. I'd prefer to use the native ones as they are less liable to do things like crash the server when fetches are aborted 😬. Especially the undici fetch implementation that ships in node is benchmarked thoroughly and achieves very high performance.
I'm wondering if there's any path toward remix's node polyfills becoming explicitly optional, conditional on node version, conditional on being missing from the global object, etc. This is perhaps complicated by the fact that the node runtime exports many of its polyfilled implementations. I'm not sure this is possible without creating an entirely new runtime, new adapters, etc.
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions