@robot-inventor/eslint-config 7.0.0 → 8.0.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/dist/cjs/index.js CHANGED
@@ -11,6 +11,9 @@ const eslint_config_prettier_1 = __importDefault(require("eslint-config-prettier
11
11
  const eslint_plugin_import_x_1 = __importDefault(require("eslint-plugin-import-x"));
12
12
  const eslint_plugin_jsdoc_1 = __importDefault(require("eslint-plugin-jsdoc"));
13
13
  const eslint_plugin_react_1 = __importDefault(require("eslint-plugin-react"));
14
+ // @ts-expect-error `eslint-plugin-react-compiler` doesn't have type definitions.
15
+ // eslint-disable-next-line import-x/max-dependencies
16
+ const eslint_plugin_react_compiler_1 = __importDefault(require("eslint-plugin-react-compiler"));
14
17
  const eslintRules = {
15
18
  curly: ["error", "multi-line"],
16
19
  "no-magic-numbers": [
@@ -108,6 +111,10 @@ exports.eslintConfig = eslintConfig;
108
111
  const eslintReactConfigBase = (0, typescript_eslint_1.config)({
109
112
  files: ["**/*.tsx"],
110
113
  ...eslint_plugin_react_1.default.configs.flat["recommended"],
114
+ plugins: {
115
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
116
+ "react-compiler": eslint_plugin_react_compiler_1.default
117
+ },
111
118
  rules: {
112
119
  "jsdoc/check-tag-names": [
113
120
  "error",
@@ -123,7 +130,8 @@ const eslintReactConfigBase = (0, typescript_eslint_1.config)({
123
130
  }
124
131
  ],
125
132
  "react/jsx-boolean-value": ["error", "never"],
126
- "react/jsx-curly-brace-presence": ["error", "never"]
133
+ "react/jsx-curly-brace-presence": ["error", "never"],
134
+ "react-compiler/react-compiler": "error"
127
135
  }
128
136
  });
129
137
  const eslintReactConfig = (0, typescript_eslint_1.config)(...eslintConfig, ...eslintReactConfigBase);
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robot-inventor/eslint-config",
3
- "version": "7.0.0",
3
+ "version": "8.0.0",
4
4
  "description": "My ESLint config preset",
5
5
  "type": "commonjs",
6
6
  "files": [
@@ -41,6 +41,7 @@
41
41
  "eslint-plugin-import-x": "^4.0.0",
42
42
  "eslint-plugin-jsdoc": "^50.0.0",
43
43
  "eslint-plugin-react": "^7.37.3",
44
+ "eslint-plugin-react-compiler": "^19.0.0-beta-e552027-20250112",
44
45
  "typescript-eslint": "^8.0.0"
45
46
  },
46
47
  "devDependencies": {
package/dist/esm/index.js CHANGED
@@ -5,6 +5,9 @@ import eslintConfigPrettier from "eslint-config-prettier";
5
5
  import importX from "eslint-plugin-import-x";
6
6
  import jsdoc from "eslint-plugin-jsdoc";
7
7
  import react from "eslint-plugin-react";
8
+ // @ts-expect-error `eslint-plugin-react-compiler` doesn't have type definitions.
9
+ // eslint-disable-next-line import-x/max-dependencies
10
+ import reactCompiler from "eslint-plugin-react-compiler";
8
11
  const eslintRules = {
9
12
  curly: ["error", "multi-line"],
10
13
  "no-magic-numbers": [
@@ -100,6 +103,10 @@ const eslintConfig = config(...eslintConfigNoJSDoc, ...JSDocRule);
100
103
  const eslintReactConfigBase = config({
101
104
  files: ["**/*.tsx"],
102
105
  ...react.configs.flat["recommended"],
106
+ plugins: {
107
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
108
+ "react-compiler": reactCompiler
109
+ },
103
110
  rules: {
104
111
  "jsdoc/check-tag-names": [
105
112
  "error",
@@ -115,7 +122,8 @@ const eslintReactConfigBase = config({
115
122
  }
116
123
  ],
117
124
  "react/jsx-boolean-value": ["error", "never"],
118
- "react/jsx-curly-brace-presence": ["error", "never"]
125
+ "react/jsx-curly-brace-presence": ["error", "never"],
126
+ "react-compiler/react-compiler": "error"
119
127
  }
120
128
  });
121
129
  const eslintReactConfig = config(...eslintConfig, ...eslintReactConfigBase);
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robot-inventor/eslint-config",
3
- "version": "7.0.0",
3
+ "version": "8.0.0",
4
4
  "description": "My ESLint config preset",
5
5
  "type": "module",
6
6
  "files": [
@@ -41,6 +41,7 @@
41
41
  "eslint-plugin-import-x": "^4.0.0",
42
42
  "eslint-plugin-jsdoc": "^50.0.0",
43
43
  "eslint-plugin-react": "^7.37.3",
44
+ "eslint-plugin-react-compiler": "^19.0.0-beta-e552027-20250112",
44
45
  "typescript-eslint": "^8.0.0"
45
46
  },
46
47
  "devDependencies": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@robot-inventor/eslint-config",
3
- "version": "7.0.0",
3
+ "version": "8.0.0",
4
4
  "description": "My ESLint config preset",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -52,6 +52,7 @@
52
52
  "eslint-plugin-import-x": "^4.0.0",
53
53
  "eslint-plugin-jsdoc": "^50.0.0",
54
54
  "eslint-plugin-react": "^7.37.3",
55
+ "eslint-plugin-react-compiler": "^19.0.0-beta-e552027-20250112",
55
56
  "typescript-eslint": "^8.0.0"
56
57
  },
57
58
  "devDependencies": {