-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
adapters now require node-fetch to be a dependency of the app #1076
Comments
I am hit by this as well trying to deploy to Netlify. Is there any kind of work around?
|
|
Weirdly I have the same problem now, neither a downgrade or installing the node-fetch as prod dependency fixes it. |
Working fine after upgrading to |
I can confirm this as well. It also should be noticed that netlify-adapter now uses .netlify subdirectory so netlify.toml should be updated accordingly. The "node-fetch" dependency should be removed completely as in sveltejs/realworld. |
This should be fixed now — #1091 |
Describe the bug
Unanticipated side-effect of #1066 —
node-fetch
isn't available when the app is built on e.g. Netlify:We could make it a peer dependency of the adapters, but that would suck. I think it might be better if adapters took responsibility for bundling the output of
svelte-kit build
(with eg.esbuild
— this functionality could also be exposed via the adapter utils). Then, if we exposed something like@sveltejs/kit/install-fetch
for the relevant adapters to use (rather than expecting them to use the correct version ofnode-fetch
and correctly assign the relevant bits toglobalThis
), it wouldn't mean needing@sveltejs/kit
to be a production dependency.Severity
Completely blocks use of the affected adapters, AFAICT
The text was updated successfully, but these errors were encountered: