@newsteam/eslint-config 0.0.63 → 0.0.67
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/lib/index.js +1 -1
- package/lib/index.mjs +1 -1
- package/lib/plugins/import/style.d.ts +5 -0
- package/lib/plugins/import/style.js +8 -3
- package/lib/plugins/import/style.mjs +8 -3
- package/package.json +7 -10
- package/lib/plugins/jsx-control-statements.d.ts +0 -17
- package/lib/plugins/jsx-control-statements.js +0 -24
- package/lib/plugins/mjsx-control-statements.js +0 -16
package/lib/index.js
CHANGED
|
@@ -13,7 +13,7 @@ const config = {
|
|
|
13
13
|
jasmine: true,
|
|
14
14
|
node: true
|
|
15
15
|
},
|
|
16
|
-
extends: ["./plugins/array-function", "./plugins/async-await", "./plugins/css-modules", "./plugins/es", "./plugins/eslint-comments", "./plugins/filenames", "./plugins/format-message", "./plugins/
|
|
16
|
+
extends: ["./plugins/array-function", "./plugins/async-await", "./plugins/css-modules", "./plugins/es", "./plugins/eslint-comments", "./plugins/filenames", "./plugins/format-message", "./plugins/import", "./plugins/more", "./plugins/no-unsanitized", "./plugins/no-useless-assign", "./plugins/node", "./plugins/optimize-regex", "./plugins/prefer-object-spread", "./plugins/promise", "./plugins/react", "./plugins/react-hooks", "./plugins/react-native", "./plugins/react-perf", "./plugins/security", "./plugins/sort-keys-fix", "./plugins/typescript", "./plugins/unicorn", "./plugins/webassembly", "./rules"].map(string => require.resolve(string)),
|
|
17
17
|
overrides: _overrides.overrides,
|
|
18
18
|
parser: "@typescript-eslint/parser",
|
|
19
19
|
parserOptions: {
|
package/lib/index.mjs
CHANGED
|
@@ -5,7 +5,7 @@ const config = {
|
|
|
5
5
|
jasmine: true,
|
|
6
6
|
node: true
|
|
7
7
|
},
|
|
8
|
-
extends: ["./plugins/array-function", "./plugins/async-await", "./plugins/css-modules", "./plugins/es", "./plugins/eslint-comments", "./plugins/filenames", "./plugins/format-message", "./plugins/
|
|
8
|
+
extends: ["./plugins/array-function", "./plugins/async-await", "./plugins/css-modules", "./plugins/es", "./plugins/eslint-comments", "./plugins/filenames", "./plugins/format-message", "./plugins/import", "./plugins/more", "./plugins/no-unsanitized", "./plugins/no-useless-assign", "./plugins/node", "./plugins/optimize-regex", "./plugins/prefer-object-spread", "./plugins/promise", "./plugins/react", "./plugins/react-hooks", "./plugins/react-native", "./plugins/react-perf", "./plugins/security", "./plugins/sort-keys-fix", "./plugins/typescript", "./plugins/unicorn", "./plugins/webassembly", "./rules"].map(string => require.resolve(string)),
|
|
9
9
|
overrides,
|
|
10
10
|
parser: "@typescript-eslint/parser",
|
|
11
11
|
parserOptions: {
|
|
@@ -33,6 +33,11 @@ declare const _default: {
|
|
|
33
33
|
"import/order": (string | {
|
|
34
34
|
groups: string[];
|
|
35
35
|
"newlines-between": string;
|
|
36
|
+
pathGroups: {
|
|
37
|
+
group: string;
|
|
38
|
+
pattern: string;
|
|
39
|
+
}[];
|
|
40
|
+
pathGroupsExcludedImportTypes: string[];
|
|
36
41
|
})[];
|
|
37
42
|
"import/prefer-default-export": string;
|
|
38
43
|
};
|
|
@@ -34,11 +34,16 @@ var _default = {
|
|
|
34
34
|
"import/no-named-export": "off",
|
|
35
35
|
"import/no-namespace": "off",
|
|
36
36
|
"import/no-unassigned-import": ["error", {
|
|
37
|
-
allow: ["@babel/polyfill", "@babel/register", "core-js/stable", "jasmine", "reflect-metadata", "regenerator-runtime/runtime", "**/*.scss", "**/*.css"]
|
|
37
|
+
allow: ["@babel/polyfill", "@babel/register", "core-js/stable", "dotenv/config", "jasmine", "reflect-metadata", "regenerator-runtime/runtime", "**/*.scss", "**/*.css"]
|
|
38
38
|
}],
|
|
39
39
|
"import/order": ["error", {
|
|
40
|
-
groups: ["builtin", "external", "internal", "sibling", "parent", "index"],
|
|
41
|
-
"newlines-between": "always"
|
|
40
|
+
groups: ["builtin", "external", "internal", "sibling", "parent", "index", "object", "type"],
|
|
41
|
+
"newlines-between": "always",
|
|
42
|
+
pathGroups: [{
|
|
43
|
+
group: "builtin",
|
|
44
|
+
pattern: "@src/**"
|
|
45
|
+
}],
|
|
46
|
+
pathGroupsExcludedImportTypes: ["builtin"]
|
|
42
47
|
}],
|
|
43
48
|
"import/prefer-default-export": "off"
|
|
44
49
|
}
|
|
@@ -28,11 +28,16 @@ export default {
|
|
|
28
28
|
"import/no-named-export": "off",
|
|
29
29
|
"import/no-namespace": "off",
|
|
30
30
|
"import/no-unassigned-import": ["error", {
|
|
31
|
-
allow: ["@babel/polyfill", "@babel/register", "core-js/stable", "jasmine", "reflect-metadata", "regenerator-runtime/runtime", "**/*.scss", "**/*.css"]
|
|
31
|
+
allow: ["@babel/polyfill", "@babel/register", "core-js/stable", "dotenv/config", "jasmine", "reflect-metadata", "regenerator-runtime/runtime", "**/*.scss", "**/*.css"]
|
|
32
32
|
}],
|
|
33
33
|
"import/order": ["error", {
|
|
34
|
-
groups: ["builtin", "external", "internal", "sibling", "parent", "index"],
|
|
35
|
-
"newlines-between": "always"
|
|
34
|
+
groups: ["builtin", "external", "internal", "sibling", "parent", "index", "object", "type"],
|
|
35
|
+
"newlines-between": "always",
|
|
36
|
+
pathGroups: [{
|
|
37
|
+
group: "builtin",
|
|
38
|
+
pattern: "@src/**"
|
|
39
|
+
}],
|
|
40
|
+
pathGroupsExcludedImportTypes: ["builtin"]
|
|
36
41
|
}],
|
|
37
42
|
"import/prefer-default-export": "off"
|
|
38
43
|
}
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@newsteam/eslint-config",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.67",
|
|
4
4
|
"description": "Shared config for eslint",
|
|
5
5
|
"main": "lib",
|
|
6
6
|
"types": "lib",
|
|
7
7
|
"scripts": {
|
|
8
|
-
"build": "make build",
|
|
9
|
-
"prepublishOnly": "make prepublish",
|
|
10
|
-
"test": "make test",
|
|
11
|
-
"update": "make update"
|
|
8
|
+
"build": "make build --always-make",
|
|
9
|
+
"prepublishOnly": "make prepublish --always-make",
|
|
10
|
+
"test": "make test --always-make",
|
|
11
|
+
"update": "make update --always-make"
|
|
12
12
|
},
|
|
13
13
|
"browserslist": "node 12",
|
|
14
14
|
"engines": {
|
|
@@ -45,15 +45,14 @@
|
|
|
45
45
|
],
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"@types/modernizr": "3.5.3",
|
|
48
|
-
"babel-eslint": "10.1.0",
|
|
49
48
|
"confusing-browser-globals": "1.0.11",
|
|
50
49
|
"eslint-import-resolver-typescript": "2.5.0"
|
|
51
50
|
},
|
|
52
51
|
"devDependencies": {
|
|
53
52
|
"@newsteam/babel": "0.0.41",
|
|
54
|
-
"@newsteam/jasmine": "0.0.
|
|
53
|
+
"@newsteam/jasmine": "0.0.38",
|
|
55
54
|
"@types/eslint": "8.2.2",
|
|
56
|
-
"@types/node": "17.0.
|
|
55
|
+
"@types/node": "17.0.10",
|
|
57
56
|
"@types/react": "17.0.38",
|
|
58
57
|
"@typescript-eslint/eslint-plugin": "5.10.0",
|
|
59
58
|
"@typescript-eslint/parser": "5.10.0",
|
|
@@ -67,7 +66,6 @@
|
|
|
67
66
|
"eslint-plugin-filenames": "1.3.2",
|
|
68
67
|
"eslint-plugin-format-message": "6.2.3",
|
|
69
68
|
"eslint-plugin-import": "2.25.4",
|
|
70
|
-
"eslint-plugin-jsx-control-statements": "2.2.1",
|
|
71
69
|
"eslint-plugin-more": "1.0.5",
|
|
72
70
|
"eslint-plugin-no-unsanitized": "4.0.1",
|
|
73
71
|
"eslint-plugin-no-useless-assign": "1.0.3",
|
|
@@ -100,7 +98,6 @@
|
|
|
100
98
|
"eslint-plugin-filenames": "1.3.2",
|
|
101
99
|
"eslint-plugin-format-message": "6.2.3",
|
|
102
100
|
"eslint-plugin-import": "2.25.4",
|
|
103
|
-
"eslint-plugin-jsx-control-statements": "2.2.1",
|
|
104
101
|
"eslint-plugin-more": "1.0.5",
|
|
105
102
|
"eslint-plugin-no-unsanitized": "4.0.1",
|
|
106
103
|
"eslint-plugin-no-useless-assign": "1.0.3",
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
declare const _default: {
|
|
2
|
-
env: {
|
|
3
|
-
"jsx-control-statements/jsx-control-statements": boolean;
|
|
4
|
-
};
|
|
5
|
-
plugins: string[];
|
|
6
|
-
rules: {
|
|
7
|
-
"jsx-control-statements/jsx-choose-not-empty": string;
|
|
8
|
-
"jsx-control-statements/jsx-for-require-each": string;
|
|
9
|
-
"jsx-control-statements/jsx-for-require-of": string;
|
|
10
|
-
"jsx-control-statements/jsx-if-require-condition": string;
|
|
11
|
-
"jsx-control-statements/jsx-jcs-no-undef": string;
|
|
12
|
-
"jsx-control-statements/jsx-otherwise-once-last": string;
|
|
13
|
-
"jsx-control-statements/jsx-use-if-tag": string;
|
|
14
|
-
"jsx-control-statements/jsx-when-require-condition": string;
|
|
15
|
-
};
|
|
16
|
-
};
|
|
17
|
-
export default _default;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.default = void 0;
|
|
7
|
-
var _default = {
|
|
8
|
-
env: {
|
|
9
|
-
"jsx-control-statements/jsx-control-statements": true
|
|
10
|
-
},
|
|
11
|
-
plugins: ["jsx-control-statements"],
|
|
12
|
-
rules: {
|
|
13
|
-
"jsx-control-statements/jsx-choose-not-empty": "error",
|
|
14
|
-
"jsx-control-statements/jsx-for-require-each": "error",
|
|
15
|
-
"jsx-control-statements/jsx-for-require-of": "error",
|
|
16
|
-
"jsx-control-statements/jsx-if-require-condition": "error",
|
|
17
|
-
"jsx-control-statements/jsx-jcs-no-undef": "error",
|
|
18
|
-
"jsx-control-statements/jsx-otherwise-once-last": "error",
|
|
19
|
-
"jsx-control-statements/jsx-use-if-tag": "error",
|
|
20
|
-
"jsx-control-statements/jsx-when-require-condition": "error"
|
|
21
|
-
}
|
|
22
|
-
};
|
|
23
|
-
exports.default = _default;
|
|
24
|
-
module.exports = exports.default;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export default {
|
|
2
|
-
env: {
|
|
3
|
-
"jsx-control-statements/jsx-control-statements": true
|
|
4
|
-
},
|
|
5
|
-
plugins: ["jsx-control-statements"],
|
|
6
|
-
rules: {
|
|
7
|
-
"jsx-control-statements/jsx-choose-not-empty": "error",
|
|
8
|
-
"jsx-control-statements/jsx-for-require-each": "error",
|
|
9
|
-
"jsx-control-statements/jsx-for-require-of": "error",
|
|
10
|
-
"jsx-control-statements/jsx-if-require-condition": "error",
|
|
11
|
-
"jsx-control-statements/jsx-jcs-no-undef": "error",
|
|
12
|
-
"jsx-control-statements/jsx-otherwise-once-last": "error",
|
|
13
|
-
"jsx-control-statements/jsx-use-if-tag": "error",
|
|
14
|
-
"jsx-control-statements/jsx-when-require-condition": "error"
|
|
15
|
-
}
|
|
16
|
-
};
|