Try it out!
- Run
npx --yes oxlint@latest
from your terminal - Install the Vscode extension https://marketplace.visualstudio.com/items?itemName=oxc.oxc-vscode
oxlint has 78 correctness rules turned on by default, with 164 rules in total.
What's Changed
Features
- Add
--deny-warnings
flag by @shannonrothe in #1452
If you wish to fail CI with exit code 1, pin oxlint
to a version and use the --deny-warnings
flag:
npx oxlint@0.0.18 --deny-warnings
Notice $?
prints 1
.
New Rules
Correctness
- eslint-plugin-unicorn: no document cookie by @camc314 in #1255
- eslint-plugin-unicorn: prefer string starts ends with by @camc314 in #1246
- eslint-plugin-jsx-a11y: anchor-has-content by @msdlisper in #1431
- eslint-plugin-jsx-a11y: html-has-lang for by @Ken-HH24 in #1436
Pedantic
- eslint-plugin-unicorn: no lonely if by @camc314 in #1252
- eslint-plugin-unicorn: no negated condition by @camc314 in #1253
- eslint-plugin-unicorn: no this assignment by @camc314 in #1250
- eslint-plugin-unicorn: no typeof undefined by @camc314 in #1251
- eslint-plugin-unicorn: no useless promise resolve reject by @camc314 in #1254
- eslint-plugin-unicorn: prefer array some by @camc314 in #1467
- eslint-plugin-unicorn: prefer dom node append by @camc314 in #1256
- eslint-plugin-unicorn: prefer dom node dataset by @camc314 in #1257
- eslint-plugin-unicorn: prefer dom node remove by @camc314 in #1472
- eslint-plugin-unicorn: prefer event target by @camc314 in #1465
- eslint-plugin-unicorn: prefer math trunc by @camc314 in #1466
- eslint-plugin-unicorn: prefer string replace all by @camc314 in #1248
- eslint-plugin-unicorn: no useless switch case by @camc314 in #1463
- eslint-plugin-unicorn: no-hex-escape by @RiESAEX in #1410
Restriction
- eslint: no-regex-spaces by @ivov in #1129
- eslint-plugin-unicorn: no-abusive-eslint-disable by @haocheng6 in #1125
- eslint-plugin-unicorn: no-nested-ternary by @haocheng6 in #1417
Style
- eslint plugin unicorn: empty-brace-spaces by @radu2147 in #1249
- eslint plugin unicorn: no zero fractions by @camc314 in #1464
- eslint plugin unicorn: prefer includes by @camc314 in #1471
- eslint-plugin-unicorn: prefer string slice by @camc314 in #1247
- eslint-plugin-unicorn: number-literal-case by @haocheng6 in #1271
- eslint-plugin-jest: max_expects by @eryue0220 in #1239
- eslint-plugin-jest: no-deprecated-function by @eryue0220 in #1316
Fixes
- eslint(for-direction): add check for condition in reverse order by @ild0tt0re in #1418
- Fix catch error name with parenthesis by @camc314 in #1242
- Fix no instanceof array with parenthesis by @camc314 in #1243
- Fix no object as default param with parenthesis by @camc314 in #1244
- Fix prefer date now with parenthesis by @camc314 in #1245
- Fix prefer logical operator error with parenthesis by @camc314 in #1241
- Fix prefer type error with parenthesis by @camc314 in #1240
- fix(parser): Disallow ReservedWord in NamedExports by @magic-akari in #1230
Misc
New Contributors
- @msdlisper made their first contribution in #1223
- @radu2147 made their first contribution in #1249
- @sirreal made their first contribution in #1416
- @Ken-HH24 made their first contribution in #1436
Full Changelog: oxlint_v0.0.17...oxlint_v0.0.18