@newsteam/eslint-config 1.2.0 → 1.2.2

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.
@@ -1 +1 @@
1
- {"version":3,"file":"perfectionist.d.ts","sourceRoot":"","sources":["../../src/plugins/perfectionist.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAER,MAAM,EACT,MAAM,QAAQ,CAAC;AAGhB,eAAO,MAAM,mBAAmB,EAAE,MAAM,CAAC,MAAM,EAyF9C,CAAC"}
1
+ {"version":3,"file":"perfectionist.d.ts","sourceRoot":"","sources":["../../src/plugins/perfectionist.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAER,MAAM,EACT,MAAM,QAAQ,CAAC;AAGhB,eAAO,MAAM,mBAAmB,EAAE,MAAM,CAAC,MAAM,EA0F9C,CAAC"}
@@ -31,6 +31,7 @@ export const perfectionistPlugin = [
31
31
  "@src/**",
32
32
  ],
33
33
  order: "asc",
34
+ sortSideEffects: true,
34
35
  type: "natural",
35
36
  },
36
37
  ],
@@ -1 +1 @@
1
- {"version":3,"file":"typescript.d.ts","sourceRoot":"","sources":["../../src/plugins/typescript.ts"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAER,MAAM,EACT,MAAM,QAAQ,CAAC;AAQhB,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAwsC3C,CAAC"}
1
+ {"version":3,"file":"typescript.d.ts","sourceRoot":"","sources":["../../src/plugins/typescript.ts"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAER,MAAM,EACT,MAAM,QAAQ,CAAC;AAQhB,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAktC3C,CAAC"}
@@ -23,6 +23,7 @@ export const typescriptPlugin = [
23
23
  rules: {
24
24
  camelcase: "off",
25
25
  "consistent-return": "off",
26
+ "default-case": "off",
26
27
  "default-param-last": "off",
27
28
  "dot-notation": "off",
28
29
  "init-declarations": "off",
@@ -109,9 +110,11 @@ export const typescriptPlugin = [
109
110
  /*
110
111
  * This rule extends the base eslint/consistent-return rule. This version adds support for functions that return void or Promise<void>.
111
112
  *
113
+ * Per the docs, using noImplicitReturns instead
114
+ *
112
115
  * https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/consistent-return.mdx
113
116
  */
114
- "@typescript-eslint/consistent-return": "error",
117
+ "@typescript-eslint/consistent-return": "off",
115
118
  /*
116
119
  * Enforces consistent usage of type assertions.
117
120
  *
@@ -1008,7 +1011,14 @@ export const typescriptPlugin = [
1008
1011
  *
1009
1012
  * https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.mdx
1010
1013
  */
1011
- "@typescript-eslint/switch-exhaustiveness-check": "error",
1014
+ "@typescript-eslint/switch-exhaustiveness-check": [
1015
+ "error",
1016
+ {
1017
+ allowDefaultCaseForExhaustiveSwitch: false,
1018
+ considerDefaultExhaustiveForUnions: false,
1019
+ requireDefaultForNonUnion: true,
1020
+ },
1021
+ ],
1012
1022
  /*
1013
1023
  * Sets preference level for triple slash directives versus ES6-style import declarations.
1014
1024
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@newsteam/eslint-config",
3
- "version": "1.2.0",
3
+ "version": "1.2.2",
4
4
  "description": "Shared config for eslint",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -51,13 +51,13 @@
51
51
  "dist"
52
52
  ],
53
53
  "dependencies": {
54
- "@babel/eslint-parser": "^7.25.7",
55
- "@babel/preset-env": "^7.25.7",
56
- "@eslint/compat": "^1.2.0",
57
- "@next/eslint-plugin-next": "^14.2.14",
58
- "@stylistic/eslint-plugin": "^2.9.0",
59
- "@typescript-eslint/eslint-plugin": "^8.8.0",
60
- "@typescript-eslint/parser": "^8.8.0",
54
+ "@babel/eslint-parser": "^7.25.9",
55
+ "@babel/preset-env": "^7.26.0",
56
+ "@eslint/compat": "^1.2.2",
57
+ "@next/eslint-plugin-next": "^15.0.2",
58
+ "@stylistic/eslint-plugin": "^2.10.1",
59
+ "@typescript-eslint/eslint-plugin": "^8.12.2",
60
+ "@typescript-eslint/parser": "^8.12.2",
61
61
  "confusing-browser-globals": "^1.0.11",
62
62
  "eslint-plugin-array-func": "^5.0.2",
63
63
  "eslint-plugin-const-case": "^1.2.2",
@@ -65,31 +65,31 @@
65
65
  "eslint-plugin-destructuring": "^2.2.1",
66
66
  "eslint-plugin-eslint-comments": "^3.2.0",
67
67
  "eslint-plugin-import-newlines": "^1.4.0",
68
- "eslint-plugin-import-x": "^4.3.1",
68
+ "eslint-plugin-import-x": "^4.4.0",
69
69
  "eslint-plugin-more": "^1.0.5",
70
70
  "eslint-plugin-newline-destructuring": "^1.2.2",
71
71
  "eslint-plugin-no-unsanitized": "^4.1.2",
72
72
  "eslint-plugin-no-useless-assign": "^1.0.3",
73
73
  "eslint-plugin-node": "^11.1.0",
74
74
  "eslint-plugin-only-warn": "^1.1.0",
75
- "eslint-plugin-perfectionist": "^3.8.0",
75
+ "eslint-plugin-perfectionist": "^3.9.1",
76
76
  "eslint-plugin-promise": "^7.1.0",
77
- "eslint-plugin-react": "^7.37.1",
77
+ "eslint-plugin-react": "^7.37.2",
78
78
  "eslint-plugin-react-19-upgrade": "^1.6.0",
79
- "eslint-plugin-react-compiler": "0.0.0-experimental-ca16900-20240916",
80
- "eslint-plugin-react-hooks": "^4.6.2",
81
- "eslint-plugin-react-perf": "^3.3.2",
82
- "eslint-plugin-react-refresh": "^0.4.12",
79
+ "eslint-plugin-react-compiler": "19.0.0-beta-9ee70a1-20241017",
80
+ "eslint-plugin-react-hooks": "^5.0.0",
81
+ "eslint-plugin-react-perf": "^3.3.3",
82
+ "eslint-plugin-react-refresh": "^0.4.14",
83
83
  "eslint-plugin-security": "^3.0.1",
84
84
  "eslint-plugin-unicorn": "^56.0.0",
85
- "globals": "^15.10.0",
86
- "typescript-eslint": "^8.8.0"
85
+ "globals": "^15.11.0",
86
+ "typescript-eslint": "^8.12.2"
87
87
  },
88
88
  "peerDependencies": {
89
89
  "eslint": ">= 9"
90
90
  },
91
91
  "devDependencies": {
92
92
  "@types/eslint-plugin-security": "^3.0.0",
93
- "@types/node": "^22.7.4"
93
+ "@types/node": "^22.8.7"
94
94
  }
95
95
  }
@@ -1,2 +0,0 @@
1
- export declare const SOMETHING = 5;
2
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/test/index.ts"],"names":[],"mappings":"AASA,eAAO,MAAM,SAAS,IAAI,CAAC"}
@@ -1,5 +0,0 @@
1
- try {
2
- console.log("test");
3
- }
4
- catch { }
5
- export const SOMETHING = 5;