eslint-config-seek
Advanced tools
Changelog
13.1.0
Adds no-fallthrough as an error. (#135) This disallows fallthrough of case statements in switch statements.
You need to add a break
, return
or throw
to 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;
}
Disable @typescript-eslint/consistent-type-definition
rule (#139)
Revert from @finsit/eslint-plugin-cypress
back to eslint-plugin-cypress
(#141)
The official plugin now supports ESLint v8. Consumers that were overriding @finsit/cypress/*
rules will need to override cypress/*
rules instead.
Changelog
12.1.1
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.
Changelog
12.1.0
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.
// 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 />}>
Changelog
12.0.0
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.
Changelog
11.3.0
react/jsx-runtime
, since we are now using the JSX transform (#118)