Skip to content

fix: avoid using Promise.allSettled in preload function #19805

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

Open
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

novlan1
Copy link

@novlan1 novlan1 commented Apr 7, 2025

Description

Add polyfill of Promise.allSettled. In some legacy browser.

@sapphi-red sapphi-red changed the title fix(allsetttled-polyfill): add polyfill of Promise.allSettled fix: avoid using Promise.allSettled in preload function Apr 8, 2025
@sapphi-red sapphi-red added has workaround p2-edge-case Bug, but has workaround or limited in scope (priority) labels Apr 8, 2025
sapphi-red
sapphi-red previously approved these changes Apr 8, 2025
Copy link
Member

@sapphi-red sapphi-red left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can have this change.

We do say "Vite does not cover polyfills." here. But for code generated by Vite, I think it would be more friendly for users if it doesn't require polyfills.
https://vite.dev/guide/build.html#browser-compatibility

If we go this way, we should ensure the code generated by Vite only uses features that are supported by the minimum browser support ranges. It fully supports ES2017 and partially supports ES2018.

@github-project-automation github-project-automation bot moved this to Discussing in Team Board Apr 8, 2025
@novlan1
Copy link
Author

novlan1 commented Apr 8, 2025

Thanks. @sapphi-red

@novlan1
Copy link
Author

novlan1 commented Apr 11, 2025

@sapphi-red Sorry to bother you. But when will this pr be merged? When will it release?

@patak-dev
Copy link
Member

Hey @novlan1, we don't have a definite time to merge PRs and do releases. To avoid being blocked by vite release process or any other project, you can patch the package to use the PR. See pnpm patch for example https://pnpm.io/cli/patch

@novlan1
Copy link
Author

novlan1 commented Apr 11, 2025

Hey @novlan1, we don't have a definite time to merge PRs and do releases. To avoid being blocked by vite release process or any other project, you can patch the package to use the PR. See pnpm patch for example https://pnpm.io/cli/patch

Got it! Thank you.

@sapphi-red sapphi-red moved this from Discussing to Approved in Team Board Apr 16, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
has workaround p2-edge-case Bug, but has workaround or limited in scope (priority)
Projects
Status: Approved
Development

Successfully merging this pull request may close these issues.

3 participants