Skip to content

fix(legacy): workaround safari 15 error caching bug#22028

Merged
sapphi-red merged 2 commits into
vitejs:mainfrom
sapphi-red:fix/legacy-workaround-safari-15-error-caching-bug
Mar 26, 2026
Merged

fix(legacy): workaround safari 15 error caching bug#22028
sapphi-red merged 2 commits into
vitejs:mainfrom
sapphi-red:fix/legacy-workaround-safari-15-error-caching-bug

Conversation

@sapphi-red
Copy link
Copy Markdown
Member

@sapphi-red sapphi-red commented Mar 26, 2026

Safari 15.x and below seems to have a bug that an error thrown in the module is only triggered once (probably related to WebKit/WebKit@92ba524). That makes the legacy browser detection to break.

To workaround that bug, this PR makes each detection module to be unique.

I tested this code on Safari 15.6.

fixes #22008

@sapphi-red sapphi-red added plugin: legacy p4-important Violate documented behavior or significantly improves performance (priority) labels Mar 26, 2026
@sapphi-red sapphi-red marked this pull request as ready for review March 26, 2026 02:48
@sapphi-red sapphi-red merged commit eb65d63 into vitejs:main Mar 26, 2026
19 checks passed
@sapphi-red sapphi-red deleted the fix/legacy-workaround-safari-15-error-caching-bug branch March 26, 2026 06:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

p4-important Violate documented behavior or significantly improves performance (priority) plugin: legacy

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Vite 8][plugin-legacy] legacy chunks not loaded when they should

1 participant