Closed anomiex closed 1 year ago
@lamansky I tried testing this using gitpkg.now.sh, and it doesn't fix the problem for me. How were you able to test this and confirm that it fixes the problem for you?
$ yarn add -D 'https://gitpkg.now.sh/lamansky/es-compat/packages/eslint-plugin-ecmascript-compat?fix-issue-30'
Editing to add: For some reason, VS Code's built-in eslint didn't pick up this change, but when executing yarn lint
from the command line to run eslint
, it appears to fix the issue. Nice!
Look what eslint-plugin-compat does: https://github.com/amilajack/eslint-plugin-compat/blob/main/src/providers/mdn-provider.ts
There is also an issue where it does the sort for oldest versions in targetRuntimes.js
Released https://github.com/robatwilliams/es-compat/releases/tag/v3.0.0
with fix for this
FYI @anomiex @dossy @lamansky @NoelDeMartin @NikolayFrantsev @ka2n
Test file:
Browserslist:
safari >= 14, ios_saf >= 14
Expected output:
Actual output:
Notes: The dataset used reports that the feature was added in version 9 of both browsers. While
14 > 9
is true,'14' > '9'
is false.