Releases: seek-oss/eslint-config-seek
v14.0.1
v14.0.0
Major Changes
-
Some language options have been restored to defaults: (#145)
sourceTypeis now set to the default ofmodule(previouslyscriptin some scenarios).ecmaVersionis now set to the default oflatest(previously2022and6)- Babel has been removed
-
Replace
eslint-plugin-importwitheslint-plugin-import-x(#145)To migrate, any references to
eslint-plugin-importshould be replaced witheslint-plugin-import-x, andimport/rules withimport-x/.In addition, it's possible that this may introduce slight behaviour changes.
-
Require TypeScript peer dependency >=5.5.4 (#145)
-
Migrate to ESLint 9,
@typescript-eslint8. (#145)These changes may affect your project setup if you are customising your ESLint configuration. See the individual migration guides:
- https://eslint.org/docs/latest/use/migrate-to-9.0.0
- https://typescript-eslint.io/blog/announcing-typescript-eslint-v8
In addition, through these major upgrades, some lint rules have changed or have been renamed. You will likely need to autofix and/or adjust your code after running ESLint.
As part of this migration, this project has migrated to Flat ESLint configuration. Read the migration guide: https://eslint.org/docs/latest/use/configure/migration-guide.
Minor Changes
-
Upgrade a number of dependencies. These should have no/minimal impact. (#145)
eslint-plugin-cypresseslint-config-prettiereslint-plugin-jesteslint-plugin-react,eslint-plugin-react-hooks
v13.1.1
v13.1.0
Minor Changes
-
Adds no-fallthrough as an error. (#135)
This disallows fallthrough of case statements in switch statements.Examples
You need to add a
break,returnorthrowto each case. You can also skip this rule if it is intentionally absent (however that is a rare scenario).switch (name) { case 'John': console.log('Hi John'); + break; }
Patch Changes
-
Disable
@typescript-eslint/consistent-type-definitionrule (#139) -
Revert from
@finsit/eslint-plugin-cypressback toeslint-plugin-cypressThe official plugin now supports ESLint v8. Consumers that were overriding
@finsit/cypress/*rules will need to overridecypress/*rules instead.
v13.0.0
v12.1.1
Patch Changes
-
Prevents the new curly-brace-presence rule from affecting children. (#133)
In the previous version, react/jsx-curly-brace-presence was added to the eslint rules.
This was primarily intended to catch unnecessarily using braces around string props.- <Stack space={'medium'}> + <Stack space="medium">
Because of the configuration we provided, this had the unintended side effect of removing curly braces inside child text that were being used to prevent the unescaped entities rule.
- <Text>The available props are {'"up"'} and {'"down"'}</Text> + <Text>The available props are "up" and "down"</Text> // This is now an unescaped entity error
To fix this, the curly brace rule will now ignore children, and only alert on prop values.
v12.1.0
Minor Changes
-
Adds react/jsx-curly-brace-presence as an error. (#130)
This removes unnecessary braces around strings in props and children.It also enforces braces around expressions in props and children.
Examples
// Unecessary braces around string prop - <Column width={'content'}> + <Column width="content">
// Unecessary braces around string child - <Text>{'Hello'}</Text> + <Text>Hello</Text>
// Mandatory braces around prop expression - <Button icon=<IconSearch />> + <Button icon={<IconSearch />}>
v12.0.1
v12.0.0
Major Changes
-
Bump up typescript-eslint monorepo to ^6.0.0. (#125)
This requires eslint 7+.
This change also includes a number of rule changes to the default configuration. Read the release notes for more information.