eslint-config-badboyku 1.0.35 → 1.0.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +17 -27
- package/.nvmrc +1 -0
- package/package.json +13 -13
package/.eslintrc.js
CHANGED
|
@@ -1,29 +1,14 @@
|
|
|
1
1
|
module.exports = {
|
|
2
|
-
globals: {
|
|
3
|
-
|
|
4
|
-
},
|
|
5
|
-
env: {
|
|
6
|
-
browser: true,
|
|
7
|
-
commonjs: true,
|
|
8
|
-
es6: true,
|
|
9
|
-
node: true,
|
|
10
|
-
jest: true,
|
|
11
|
-
},
|
|
12
|
-
parserOptions: {
|
|
13
|
-
ecmaFeatures: { jsx: true },
|
|
14
|
-
sourceType: 'module',
|
|
15
|
-
},
|
|
2
|
+
globals: { __DEV__: true },
|
|
3
|
+
env: { browser: true, commonjs: true, es6: true, node: true, jest: true },
|
|
4
|
+
parserOptions: { ecmaFeatures: { jsx: true }, sourceType: 'module' },
|
|
16
5
|
extends: ['airbnb', 'airbnb/hooks', 'eslint:recommended', 'plugin:import/recommended', 'plugin:prettier/recommended'],
|
|
17
6
|
plugins: ['import', 'prettier'],
|
|
18
|
-
settings: {
|
|
19
|
-
'import/resolver': { node: { extensions: ['.js', '.jsx', '.ts', '.tsx'] } },
|
|
20
|
-
},
|
|
7
|
+
settings: { 'import/resolver': { node: { extensions: ['.js', '.jsx', '.ts', '.tsx'] } } },
|
|
21
8
|
overrides: [
|
|
22
9
|
{
|
|
23
10
|
files: ['**/*.[jt]sx'],
|
|
24
|
-
settings: {
|
|
25
|
-
react: { version: 'detect' },
|
|
26
|
-
},
|
|
11
|
+
settings: { react: { version: 'detect' } },
|
|
27
12
|
extends: ['plugin:jsx-a11y/recommended', 'plugin:react/recommended', 'plugin:react-hooks/recommended'],
|
|
28
13
|
plugins: ['jsx-a11y', 'react', 'react-hooks'],
|
|
29
14
|
rules: {
|
|
@@ -76,9 +61,7 @@ module.exports = {
|
|
|
76
61
|
},
|
|
77
62
|
{
|
|
78
63
|
files: ['**/__tests__/**/*.[jt]s?(x)', '**/?(*.)+(spec|test).[jt]s?(x)'],
|
|
79
|
-
settings: {
|
|
80
|
-
jest: { version: 'detect' },
|
|
81
|
-
},
|
|
64
|
+
settings: { jest: { version: 'detect' } },
|
|
82
65
|
extends: ['plugin:jest/recommended', 'plugin:jest-dom/recommended', 'plugin:testing-library/react'],
|
|
83
66
|
plugins: ['jest', 'jest-dom', 'testing-library'],
|
|
84
67
|
rules: {
|
|
@@ -95,10 +78,17 @@ module.exports = {
|
|
|
95
78
|
extends: ['plugin:@typescript-eslint/recommended'],
|
|
96
79
|
plugins: ['@typescript-eslint'],
|
|
97
80
|
rules: {
|
|
98
|
-
'@typescript-eslint/
|
|
99
|
-
'@typescript-eslint/no-
|
|
81
|
+
'@typescript-eslint/no-empty-object-type': ['warn', { allowInterfaces: 'always', allowObjectTypes: 'always' }],
|
|
82
|
+
'@typescript-eslint/no-unused-vars': [
|
|
83
|
+
'warn',
|
|
84
|
+
{
|
|
85
|
+
argsIgnorePattern: '^_',
|
|
86
|
+
caughtErrorsIgnorePattern: '^_',
|
|
87
|
+
destructuredArrayIgnorePattern: '^_',
|
|
88
|
+
varsIgnorePattern: '^_',
|
|
89
|
+
},
|
|
90
|
+
],
|
|
100
91
|
'@typescript-eslint/no-use-before-define': ['warn', { functions: false, classes: false, variables: false }],
|
|
101
|
-
'@typescript-eslint/no-unused-vars': ['warn', { argsIgnorePattern: '^_' }],
|
|
102
92
|
'react/jsx-filename-extension': ['warn', { extensions: ['.tsx'] }],
|
|
103
93
|
},
|
|
104
94
|
},
|
|
@@ -123,7 +113,7 @@ module.exports = {
|
|
|
123
113
|
'no-constant-condition': ['error', { checkLoops: false }],
|
|
124
114
|
'no-param-reassign': ['warn', { props: false }],
|
|
125
115
|
'no-underscore-dangle': 'off',
|
|
126
|
-
'no-unused-vars': ['warn', { argsIgnorePattern: '^_' }],
|
|
116
|
+
'no-unused-vars': ['warn', { argsIgnorePattern: '^_', varsIgnorePattern: '^_' }],
|
|
127
117
|
'no-use-before-define': 'off',
|
|
128
118
|
'padding-line-between-statements': ['warn', { blankLine: 'always', prev: '*', next: 'return' }],
|
|
129
119
|
'prettier/prettier': [
|
package/.nvmrc
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
v22.13.1
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eslint-config-badboyku",
|
|
3
3
|
"description": "Shared eslint+prettier configuration with react/jest/typescript support.",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.37",
|
|
5
5
|
"author": "badboyku",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"repository": {
|
|
@@ -16,20 +16,20 @@
|
|
|
16
16
|
"prettier:fix": "prettier --write \"**/*.{css,scss,json}\""
|
|
17
17
|
},
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
20
|
-
"@typescript-eslint/parser": "^
|
|
21
|
-
"eslint": "^8.57.
|
|
19
|
+
"@typescript-eslint/eslint-plugin": "^8.23.0",
|
|
20
|
+
"@typescript-eslint/parser": "^8.23.0",
|
|
21
|
+
"eslint": "^8.57.1",
|
|
22
22
|
"eslint-config-airbnb": "^19.0.4",
|
|
23
23
|
"eslint-config-prettier": "^9.1.0",
|
|
24
|
-
"eslint-plugin-import": "^2.
|
|
25
|
-
"eslint-plugin-jest": "^28.
|
|
26
|
-
"eslint-plugin-jest-dom": "^5.
|
|
27
|
-
"eslint-plugin-jsx-a11y": "^6.
|
|
28
|
-
"eslint-plugin-prettier": "^5.
|
|
29
|
-
"eslint-plugin-react": "^7.
|
|
24
|
+
"eslint-plugin-import": "^2.31.0",
|
|
25
|
+
"eslint-plugin-jest": "^28.11.0",
|
|
26
|
+
"eslint-plugin-jest-dom": "^5.5.0",
|
|
27
|
+
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
28
|
+
"eslint-plugin-prettier": "^5.2.3",
|
|
29
|
+
"eslint-plugin-react": "^7.37.4",
|
|
30
30
|
"eslint-plugin-react-hooks": "^4.6.2",
|
|
31
|
-
"eslint-plugin-testing-library": "^6.
|
|
32
|
-
"prettier": "^3.2
|
|
33
|
-
"typescript": "^5.
|
|
31
|
+
"eslint-plugin-testing-library": "^6.5.0",
|
|
32
|
+
"prettier": "^3.4.2",
|
|
33
|
+
"typescript": "^5.7.3"
|
|
34
34
|
}
|
|
35
35
|
}
|