Update linting
This commit is contained in:
13
.eslintrc.js
13
.eslintrc.js
@@ -4,9 +4,11 @@ module.exports = {
|
|||||||
'plugin:@next/next/recommended',
|
'plugin:@next/next/recommended',
|
||||||
'plugin:jest/recommended',
|
'plugin:jest/recommended',
|
||||||
'plugin:storybook/recommended',
|
'plugin:storybook/recommended',
|
||||||
'plugin:@typescript-eslint/eslint-recommended',
|
"eslint:recommended",
|
||||||
|
"plugin:@typescript-eslint/eslint-recommended",
|
||||||
|
"plugin:@typescript-eslint/recommended"
|
||||||
],
|
],
|
||||||
plugins: ['testing-library', 'jest', 'react-hooks', 'react'],
|
plugins: ['testing-library', 'jest', 'react-hooks', 'react', 'unused-imports'],
|
||||||
overrides: [
|
overrides: [
|
||||||
{
|
{
|
||||||
files: ['**/?(*.)+(spec|test).[jt]s?(x)'],
|
files: ['**/?(*.)+(spec|test).[jt]s?(x)'],
|
||||||
@@ -18,5 +20,12 @@ module.exports = {
|
|||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
'react/react-in-jsx-scope': 'off',
|
'react/react-in-jsx-scope': 'off',
|
||||||
|
"unused-imports/no-unused-imports": "warn",
|
||||||
|
"@typescript-eslint/no-unused-vars": "off",
|
||||||
|
"@typescript-eslint/no-unused-imports": "off",
|
||||||
|
"@typescript-eslint/no-unused-expressions": "off",
|
||||||
|
"@typescript-eslint/no-explicit-any": "off",
|
||||||
|
"@typescript-eslint/no-shadow": "off",
|
||||||
|
"@typescript-eslint/no-use-before-define": "off",
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -68,6 +68,7 @@
|
|||||||
"eslint-plugin-react-hooks": "^4.3.0",
|
"eslint-plugin-react-hooks": "^4.3.0",
|
||||||
"eslint-plugin-storybook": "^0.5.11",
|
"eslint-plugin-storybook": "^0.5.11",
|
||||||
"eslint-plugin-testing-library": "^5.2.0",
|
"eslint-plugin-testing-library": "^5.2.0",
|
||||||
|
"eslint-plugin-unused-imports": "^2.0.0",
|
||||||
"jest": "^27.5.1",
|
"jest": "^27.5.1",
|
||||||
"prettier": "^2.6.2",
|
"prettier": "^2.6.2",
|
||||||
"storybook-addon-turbo-build": "^1.1.0",
|
"storybook-addon-turbo-build": "^1.1.0",
|
||||||
|
|||||||
12
yarn.lock
12
yarn.lock
@@ -5938,6 +5938,18 @@ eslint-plugin-testing-library@^5.2.0:
|
|||||||
dependencies:
|
dependencies:
|
||||||
"@typescript-eslint/utils" "^5.13.0"
|
"@typescript-eslint/utils" "^5.13.0"
|
||||||
|
|
||||||
|
eslint-plugin-unused-imports@^2.0.0:
|
||||||
|
version "2.0.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/eslint-plugin-unused-imports/-/eslint-plugin-unused-imports-2.0.0.tgz#d8db8c4d0cfa0637a8b51ce3fd7d1b6bc3f08520"
|
||||||
|
integrity sha512-3APeS/tQlTrFa167ThtP0Zm0vctjr4M44HMpeg1P4bK6wItarumq0Ma82xorMKdFsWpphQBlRPzw/pxiVELX1A==
|
||||||
|
dependencies:
|
||||||
|
eslint-rule-composer "^0.3.0"
|
||||||
|
|
||||||
|
eslint-rule-composer@^0.3.0:
|
||||||
|
version "0.3.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/eslint-rule-composer/-/eslint-rule-composer-0.3.0.tgz#79320c927b0c5c0d3d3d2b76c8b4a488f25bbaf9"
|
||||||
|
integrity sha512-bt+Sh8CtDmn2OajxvNO+BX7Wn4CIWMpTRm3MaiKPCQcnnlm0CS2mhui6QaoeQugs+3Kj2ESKEEGJUdVafwhiCg==
|
||||||
|
|
||||||
eslint-scope@^4.0.3:
|
eslint-scope@^4.0.3:
|
||||||
version "4.0.3"
|
version "4.0.3"
|
||||||
resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848"
|
resolved "https://registry.yarnpkg.com/eslint-scope/-/eslint-scope-4.0.3.tgz#ca03833310f6889a3264781aa82e63eb9cfe7848"
|
||||||
|
|||||||
Reference in New Issue
Block a user