whatwg-fetch removed from production bundle #3071
Unanswered
gaelollivier
asked this question in
Troubleshooting
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am trying to use
whatwg-fetch
to polyfillfetch
on IE 11. Snowpack seems to overridenode-fetch
andwhatwg-fetch
with a native polyfill. In the code, it says this should still allow to polyfill in older browsers: https://github.com/snowpackjs/snowpack/blob/fc6c1417a09ac85e02730033660391d299a5fd97/esinstall/src/rollup-plugins/rollup-plugin-catch-fetch.ts#L28However I don't see how I am supposed to achieve this. I made a small reproduction repository where I pushed the output from
yarn build
: https://github.com/gaelduplessix/snowpack-app/blob/whatwg-fetch/build/_snowpack/pkg/whatwg-fetch.jswhatwg-fetch
is replaced by snowpack and prevents it from being included in my production bundle. I am not sure if this is a bug in snowpack or if there is another recommended way to include polyfills? Thanks!Beta Was this translation helpful? Give feedback.
All reactions