Does Vite block old browsers, like Safari 12, by using Promise.allSettled
?
#18845
kevinrenskers
started this conversation in
Feedback
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have a SvelteKit website, which uses Vite 5. I am getting error reports in Sentry about the use of
Promise.allSettled
, all coming from Safari 12 / Mobile Safari 12 users, which indeed has no support forPromise.allSettled
. I was surprised by this usage, as I don't use it, and Svelte and SvelteKit also don't use it.Digging in a bit deeper it seems that this code is coming from Vite itself. Here is a screenshot of my build chunk where sure enough
Promise.allSettled
is being used:Put through https://beautifier.io, the code looks like this:
And this seems to come from Vite's
client.mjs
. So is Vite breaking my site in Safari 12? What can I do about this?Sadly I cannot use
plugin-legacy
, as it doesn't seem to work with SvelteKit :(Beta Was this translation helpful? Give feedback.
All reactions