eslint-config-teselagen 6.0.7 → 6.0.9

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/base-config.js ADDED
@@ -0,0 +1,8 @@
1
+ module.exports = {
2
+ rules: {
3
+ "no-unused-vars": 0,
4
+ "@typescript-eslint/no-unused-vars": [1, { ignoreRestSiblings: true }],
5
+ "no-use-before-define": 0,
6
+ "@typescript-eslint/no-use-before-define": 1,
7
+ },
8
+ };
package/cypress.js CHANGED
@@ -1,8 +1,9 @@
1
1
  require("@rushstack/eslint-patch/modern-module-resolution");
2
2
 
3
3
  module.exports = {
4
- plugins: ["cypress", "no-only-tests"],
5
- extends: ["plugin:cypress/recommended"],
4
+ plugins: ["cypress", "no-only-tests", "@typescript-eslint"],
5
+ parser: "@typescript-eslint/parser",
6
+ extends: ["./base-config.js", "plugin:cypress/recommended"],
6
7
  env: {
7
8
  "cypress/globals": true,
8
9
  },
@@ -0,0 +1,19 @@
1
+ module.exports = {
2
+ rules: {
3
+ "no-var": 2,
4
+ "no-console": [1, { allow: ["warn", "error", "info"] }],
5
+ "no-debugger": 2,
6
+ "no-empty": [2],
7
+ "no-extra-boolean-cast": 2,
8
+ "no-extra-semi": 1,
9
+ "no-inner-declarations": [2, "functions"],
10
+ "no-undef": 2,
11
+ "no-unneeded-ternary": 1,
12
+ "no-unsafe-negation": 2,
13
+ "import/no-unresolved": 2,
14
+ "import/no-anonymous-default-export": 0,
15
+ "import/named": 2,
16
+ "import/default": 2,
17
+ "prefer-const": [1, { destructuring: "all" }],
18
+ },
19
+ };
package/node.js CHANGED
@@ -1,32 +1,18 @@
1
1
  require("@rushstack/eslint-patch/modern-module-resolution");
2
2
 
3
3
  module.exports = {
4
- extends: "react-app",
4
+ extends: ["./base-config.js", "./node-react-config.js", "react-app"],
5
+ parser: "@typescript-eslint/parser",
6
+ plugins: ["@typescript-eslint"],
5
7
  env: {
6
8
  node: true,
7
9
  browser: true,
8
10
  mocha: true,
9
11
  },
10
12
  rules: {
11
- "import/no-anonymous-default-export": 0,
12
- "no-undef": 2,
13
- "no-console": [1, { allow: ["warn", "error", "info"] }],
14
- "no-unused-vars": 1,
15
13
  "no-redeclare": 2,
16
14
  "comma-dangle": 0,
17
15
  "no-mixed-spaces-and-tabs": 0,
18
16
  "linebreak-style": [0, "unix"],
19
- "no-var": 2,
20
- "no-debugger": 2,
21
- "no-empty": [2],
22
- "no-extra-boolean-cast": 2,
23
- "no-extra-semi": 1,
24
- "no-inner-declarations": [2, "functions"],
25
- "no-unneeded-ternary": 1,
26
- "no-unsafe-negation": 2,
27
- "import/no-unresolved": 2,
28
- "import/named": 2,
29
- "import/default": 2,
30
- "prefer-const": [1, { destructuring: "all" }],
31
17
  },
32
- };
18
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-config-teselagen",
3
- "version": "6.0.7",
3
+ "version": "6.0.9",
4
4
  "description": "teselagen linter rules",
5
5
  "repository": "https://github.com/TeselaGen/eslint-config-teselagen.git",
6
6
  "author": "teselagen team@teselagen",
@@ -28,5 +28,8 @@
28
28
  "husky": "^0.14.3",
29
29
  "lint-staged": "^7.2.0",
30
30
  "prettier": "^1.13.7"
31
+ },
32
+ "devDependencies": {
33
+ "typescript": "^4.8.4"
31
34
  }
32
35
  }
package/react.js CHANGED
@@ -1,27 +1,12 @@
1
1
  require("@rushstack/eslint-patch/modern-module-resolution");
2
2
 
3
3
  module.exports = {
4
- extends: "react-app",
4
+ extends: ["./base-config.js", "./node-react-config.js", "react-app"],
5
+ parser: "@typescript-eslint/parser",
6
+ plugins: ["@typescript-eslint"],
5
7
  rules: {
6
- "import/no-anonymous-default-export": 0,
7
- "no-var": 2,
8
- "no-console": [1, { allow: ["warn", "error", "info"] }],
9
- "no-debugger": 2,
10
- "no-empty": [2],
11
- "no-extra-boolean-cast": 2,
12
- "no-extra-semi": 1,
13
- "no-inner-declarations": [2, "functions"],
14
- "no-undef": 2,
15
- "no-unneeded-ternary": 1,
16
- "no-unsafe-negation": 2,
17
- "import/no-unresolved": 2,
18
- "import/named": 2,
19
8
  "no-const-assign": 2,
20
- "import/default": 2,
21
9
  "react/jsx-boolean-value": 0,
22
10
  "react/jsx-key": 2,
23
- "prefer-const": [1, { destructuring: "all" }],
24
- "no-unused-vars": 0,
25
- "@typescript-eslint/no-unused-vars": [1, { ignoreRestSiblings: true }],
26
11
  },
27
12
  };