Description
Hello,
When I launch the svelte tutorial on https://svelte.dev/tutorial/svelte/welcome-to-svelte, it seems to get stuck on "loading svelte compiler".
in the console, I can see 2 error messages
so it seems the tutorial breaks because Promise.withTransformers is not available.
This could be the explanation of why it does not work on windows 8.1 because the main browsers on 8.1 are stuck on LTS versions specific to windows 8.1 like chrome 109 and firefox 115
According to https://caniuse.com/mdn-javascript_builtins_promise_withresolvers withResolvers is not available on these versions.
Would it be possible in the case that withResolvers is not available, the tutorial would use a polyfill like
if (typeof Promise.withResolvers === "undefined") {
Promise.withResolvers = <T>() => {
let resolve!: (value: T | PromiseLike<T>) => void;
let reject!: (reason?: unknown) => void;
const promise = new Promise<T>((res, rej) => {
resolve = res;
reject = rej;
});
return { promise, resolve, reject };
};
}
After writing this, I realized that you already have a polyfill for this in the code in https://github.com/sveltejs/svelte.dev/blame/main/packages/site-kit/src/lib/polyfills/index.ts that was commited 3 months ago.
could it be that this commit has not yet reached the tutorial on https://svelte.dev/tutorial/svelte/welcome-to-svelte ?