eslint-config-adslot 1.2.0 → 1.3.0
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/README.md +2 -14
- package/index.js +9 -3
- package/package.json +13 -14
package/README.md
CHANGED
@@ -8,10 +8,10 @@ ESLint configuration for Adslot
|
|
8
8
|
## Install
|
9
9
|
|
10
10
|
```
|
11
|
-
npm install -D eslint-config-adslot
|
11
|
+
npm install -D eslint-config-adslot eslint
|
12
12
|
```
|
13
13
|
|
14
|
-
`eslint`
|
14
|
+
`eslint` is a required peer dependencies
|
15
15
|
|
16
16
|
## Setup
|
17
17
|
|
@@ -23,18 +23,6 @@ Add the following to your eslint config file, ususally `.eslintrc`,
|
|
23
23
|
}
|
24
24
|
```
|
25
25
|
|
26
|
-
## Babel config
|
27
|
-
|
28
|
-
When not using `babel.config.js` in project root direct, add the following to `eslintrc` file.
|
29
|
-
|
30
|
-
```
|
31
|
-
parserOptions: {
|
32
|
-
babelOptions: {
|
33
|
-
configFile: 'path/to/babelrc',
|
34
|
-
},
|
35
|
-
}
|
36
|
-
```
|
37
|
-
|
38
26
|
## Features
|
39
27
|
|
40
28
|
This config includes
|
package/index.js
CHANGED
@@ -6,8 +6,6 @@
|
|
6
6
|
const restrictedGlobals = require('confusing-browser-globals');
|
7
7
|
|
8
8
|
module.exports = {
|
9
|
-
parser: '@babel/eslint-parser',
|
10
|
-
|
11
9
|
env: {
|
12
10
|
browser: true,
|
13
11
|
commonjs: true,
|
@@ -18,6 +16,7 @@ module.exports = {
|
|
18
16
|
},
|
19
17
|
|
20
18
|
parserOptions: {
|
19
|
+
ecmaVersion: 'latest',
|
21
20
|
sourceType: 'module',
|
22
21
|
ecmaFeatures: {
|
23
22
|
jsx: true,
|
@@ -30,7 +29,7 @@ module.exports = {
|
|
30
29
|
},
|
31
30
|
'import/resolver': {
|
32
31
|
node: {
|
33
|
-
extensions: ['.ts', '.tsx', '.js', '.jsx'],
|
32
|
+
extensions: ['.ts', '.tsx', '.js', '.jsx', '.mjs'],
|
34
33
|
},
|
35
34
|
},
|
36
35
|
},
|
@@ -42,6 +41,7 @@ module.exports = {
|
|
42
41
|
'react-hooks',
|
43
42
|
'lodash',
|
44
43
|
'chai-friendly',
|
44
|
+
'jest',
|
45
45
|
],
|
46
46
|
|
47
47
|
extends: ['prettier'],
|
@@ -235,6 +235,7 @@ module.exports = {
|
|
235
235
|
],
|
236
236
|
'import/no-cycle': 'error',
|
237
237
|
'import/no-unresolved': ['error', { commonjs: true }],
|
238
|
+
'import/no-duplicates': 'error',
|
238
239
|
|
239
240
|
// https://github.com/yannickcr/eslint-plugin-react/tree/master/docs/rules
|
240
241
|
'react/forbid-foreign-prop-types': ['error', { allowInPropTypes: true }],
|
@@ -321,5 +322,10 @@ module.exports = {
|
|
321
322
|
'lodash/chain-style': ['error', 'as-needed'],
|
322
323
|
'lodash/chaining': ['error', 'always'],
|
323
324
|
'lodash/path-style': ['error', 'string'],
|
325
|
+
|
326
|
+
// https://github.com/jest-community/eslint-plugin-jest
|
327
|
+
// could also be used in non-jest tests
|
328
|
+
'jest/no-disabled-tests': 'error',
|
329
|
+
'jest/no-focused-tests': 'error',
|
324
330
|
},
|
325
331
|
};
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "eslint-config-adslot",
|
3
|
-
"version": "1.
|
3
|
+
"version": "1.3.0",
|
4
4
|
"description": "ESLint configuration for Adslot",
|
5
5
|
"main": "index.js",
|
6
6
|
"files": [
|
@@ -31,20 +31,19 @@
|
|
31
31
|
"release:patch": "npm version patch -m 'build: release patch version %s'"
|
32
32
|
},
|
33
33
|
"dependencies": {
|
34
|
-
"@typescript-eslint/eslint-plugin": "^
|
35
|
-
"@typescript-eslint/parser": "^
|
36
|
-
"confusing-browser-globals": "^1.0.
|
37
|
-
"eslint-config-prettier": "^8.
|
34
|
+
"@typescript-eslint/eslint-plugin": "^5.30.0",
|
35
|
+
"@typescript-eslint/parser": "^5.30.0",
|
36
|
+
"confusing-browser-globals": "^1.0.11",
|
37
|
+
"eslint-config-prettier": "^8.5.0",
|
38
38
|
"eslint-plugin-chai-friendly": "^0.7.2",
|
39
|
-
"eslint-plugin-import": "^2.
|
40
|
-
"eslint-plugin-
|
41
|
-
"eslint-plugin-
|
42
|
-
"eslint-plugin-
|
43
|
-
"eslint-plugin-react
|
39
|
+
"eslint-plugin-import": "^2.26.0",
|
40
|
+
"eslint-plugin-jest": "^27.0.1",
|
41
|
+
"eslint-plugin-jsx-a11y": "^6.6.0",
|
42
|
+
"eslint-plugin-lodash": "^7.4.0",
|
43
|
+
"eslint-plugin-react": "^7.30.1",
|
44
|
+
"eslint-plugin-react-hooks": "^4.6.0"
|
44
45
|
},
|
45
46
|
"peerDependencies": {
|
46
|
-
"
|
47
|
-
|
48
|
-
},
|
49
|
-
"devDependencies": {}
|
47
|
+
"eslint": "^8.18.0"
|
48
|
+
}
|
50
49
|
}
|