Repository navigation
fix(clients): replace toSorted with sort in bundled code - #14120
maximevast wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
There was a problem hiding this comment.
No issues found across 7 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Auto-approved: Fixes ES2023 incompatibility by replacing toSorted with sort in bundled client code, using spreads to avoid mutation. Bounded, focused change with no behavioral shift.
Re-trigger cubic
sebastianekstrom
left a comment
There was a problem hiding this comment.
Not sure we actually need this. It seems to be a very widely supported API: https://caniuse.com/?search=toSorted. Firefox 115 was released back in 2023, so people have had plenty of time to upgrade!
|
My reasoning was that it's in checkout and thus could be seen by a wide range of people. I agree that merchants are surely using an up to date browser, but was mainly thinking about customers. Happy to discard if you think this is too far fetched. |
Summary
Closes #14111
Bundled code can't use ES2023 APIs.
toSortedis ES2023.Our floor is Next 16's default target,
baseline widely available:Chrome/Edge 111, Firefox 111, Safari 16.4.
toSortedneeds Firefox 115.Checklist
uv run task lint && uv run task lint_types)