@greenberry/linting-config 0.2.4 → 0.2.5
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/eslint.config.js
CHANGED
|
@@ -3,7 +3,7 @@ import importPlugin from "eslint-plugin-import";
|
|
|
3
3
|
import jsxA11yPlugin from "eslint-plugin-jsx-a11y";
|
|
4
4
|
import perfectionistPlugin from "eslint-plugin-perfectionist";
|
|
5
5
|
import prettierPlugin from "eslint-plugin-prettier";
|
|
6
|
-
import
|
|
6
|
+
import eslintReact from "@eslint-react/eslint-plugin";
|
|
7
7
|
import reactCompilerPlugin from "eslint-plugin-react-compiler";
|
|
8
8
|
import reactHooksPlugin from "eslint-plugin-react-hooks";
|
|
9
9
|
import reactHooksExtraPlugin from "eslint-plugin-react-hooks-extra";
|
|
@@ -24,6 +24,9 @@ const reactHooksExtraPluginTyped = {
|
|
|
24
24
|
meta: reactHooksExtraPlugin.meta,
|
|
25
25
|
rules: reactHooksExtraPlugin.rules,
|
|
26
26
|
};
|
|
27
|
+
const eslintReactPlugins =
|
|
28
|
+
// @ts-ignore - plugins property exists at runtime but not in types
|
|
29
|
+
eslintReact.configs.recommended.plugins || {};
|
|
27
30
|
export default defineConfig(eslint.configs.recommended, tseslint.configs.strict, tseslint.configs.stylistic, {
|
|
28
31
|
files: ["**/*.{js,mjs,cjs,jsx,ts,tsx}"],
|
|
29
32
|
languageOptions: {
|
|
@@ -43,7 +46,7 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
43
46
|
},
|
|
44
47
|
},
|
|
45
48
|
plugins: {
|
|
46
|
-
|
|
49
|
+
...eslintReactPlugins,
|
|
47
50
|
"react-hooks": reactHooksPluginTyped,
|
|
48
51
|
"react-hooks-extra": reactHooksExtraPluginTyped,
|
|
49
52
|
import: importPlugin,
|
|
@@ -52,6 +55,7 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
52
55
|
"jsx-a11y": jsxA11yPlugin,
|
|
53
56
|
prettier: prettierPlugin,
|
|
54
57
|
"react-compiler": reactCompilerPlugin,
|
|
58
|
+
storybook: storybookPlugin,
|
|
55
59
|
},
|
|
56
60
|
settings: {
|
|
57
61
|
"import/resolver": {
|
|
@@ -64,8 +68,7 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
64
68
|
},
|
|
65
69
|
},
|
|
66
70
|
rules: {
|
|
67
|
-
|
|
68
|
-
...reactPlugin.configs["jsx-runtime"].rules,
|
|
71
|
+
...eslintReact.configs.recommended.rules,
|
|
69
72
|
...reactHooksPlugin.configs.recommended.rules,
|
|
70
73
|
...jsxA11yPlugin.configs.recommended.rules,
|
|
71
74
|
// TypeScript rules
|
|
@@ -98,22 +101,18 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
98
101
|
disallowTypeAnnotations: false,
|
|
99
102
|
},
|
|
100
103
|
],
|
|
101
|
-
// React rules
|
|
102
|
-
"react/
|
|
103
|
-
"react/jsx-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
"react/
|
|
104
|
+
// React rules (using @eslint-react/eslint-plugin)
|
|
105
|
+
"@eslint-react/no-array-index-key": "error",
|
|
106
|
+
"@eslint-react/jsx-shorthand-boolean": "error",
|
|
107
|
+
"@eslint-react/no-unnecessary-use-prefix": "warn",
|
|
108
|
+
"@eslint-react/no-unused-props": "error",
|
|
109
|
+
"@eslint-react/no-unused-state": "error",
|
|
110
|
+
"@eslint-react/dom/no-void-elements-with-children": "error",
|
|
111
|
+
"@eslint-react/naming-convention/filename-extension": [
|
|
108
112
|
"error",
|
|
109
113
|
{ extensions: [".jsx", ".tsx"] },
|
|
110
114
|
],
|
|
111
|
-
"react/no-array-index-key": "error",
|
|
112
|
-
"react/no-unused-prop-types": "error",
|
|
113
|
-
"react/no-unused-state": "error",
|
|
114
|
-
"react/void-dom-elements-no-children": "error",
|
|
115
115
|
"react-hooks/exhaustive-deps": "error",
|
|
116
|
-
"react/no-object-type-as-default-prop": "error",
|
|
117
116
|
"react-compiler/react-compiler": "error",
|
|
118
117
|
// Import rules
|
|
119
118
|
"import/extensions": [
|
|
@@ -176,12 +175,11 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
176
175
|
groups: ["key", "ref", "id", "unknown", "className"],
|
|
177
176
|
},
|
|
178
177
|
],
|
|
179
|
-
// React Hooks Extra rules
|
|
180
|
-
"react
|
|
181
|
-
"react-
|
|
182
|
-
"react-
|
|
183
|
-
"react
|
|
184
|
-
"react-hooks-extra/no-unnecessary-use-memo": "warn",
|
|
178
|
+
// React Hooks Extra rules (migrated to @eslint-react/eslint-plugin)
|
|
179
|
+
"@eslint-react/hooks-extra/no-direct-set-state-in-use-effect": "warn",
|
|
180
|
+
"@eslint-react/prefer-use-state-lazy-initialization": "warn",
|
|
181
|
+
"@eslint-react/no-unnecessary-use-callback": "warn",
|
|
182
|
+
"@eslint-react/no-unnecessary-use-memo": "warn",
|
|
185
183
|
// Other rules
|
|
186
184
|
"jsx-a11y/alt-text": "error",
|
|
187
185
|
"jsx-a11y/media-has-caption": "warn",
|
|
@@ -210,21 +208,31 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
210
208
|
},
|
|
211
209
|
},
|
|
212
210
|
// Storybook stories configuration
|
|
213
|
-
|
|
211
|
+
{
|
|
214
212
|
files: [
|
|
215
213
|
"**/*.stories.@(js|jsx|ts|tsx|mjs|cjs|mdx)",
|
|
216
214
|
"**/*.story.@(js|jsx|ts|tsx|mjs|cjs|mdx)",
|
|
217
215
|
],
|
|
216
|
+
plugins: {
|
|
217
|
+
storybook: storybookPlugin,
|
|
218
|
+
},
|
|
218
219
|
rules: {
|
|
220
|
+
// Storybook recommended rules for story files
|
|
221
|
+
"storybook/await-interactions": "error",
|
|
222
|
+
"storybook/context-in-play-function": "error",
|
|
223
|
+
"storybook/default-exports": "error",
|
|
219
224
|
"storybook/hierarchy-separator": "warn",
|
|
220
225
|
"storybook/no-redundant-story-name": "warn",
|
|
221
|
-
"storybook/no-stories-of": "error",
|
|
222
|
-
"storybook/no-title-property-in-meta": "error", // Use title in default export
|
|
226
|
+
"storybook/no-stories-of": "error",
|
|
223
227
|
"storybook/prefer-pascal-case": "warn",
|
|
224
|
-
|
|
225
|
-
"
|
|
226
|
-
"
|
|
227
|
-
"react-
|
|
228
|
+
"storybook/story-exports": "error",
|
|
229
|
+
"storybook/use-storybook-expect": "error",
|
|
230
|
+
"storybook/use-storybook-testing-library": "error",
|
|
231
|
+
"@eslint-react/naming-convention/filename-extension": "off",
|
|
232
|
+
"@eslint-react/no-array-index-key": "off", // Allow index as key in story files
|
|
233
|
+
"react-hooks/rules-of-hooks": "off",
|
|
234
|
+
"import/no-anonymous-default-export": "off",
|
|
235
|
+
"react-hooks/exhaustive-deps": "warn",
|
|
228
236
|
},
|
|
229
237
|
},
|
|
230
238
|
// Storybook main config file
|
|
@@ -243,7 +251,6 @@ export default defineConfig(eslint.configs.recommended, tseslint.configs.strict,
|
|
|
243
251
|
"src/env.ts",
|
|
244
252
|
"**/*.gql",
|
|
245
253
|
"next-env.d.ts",
|
|
246
|
-
"!.storybook", // Allow linting of .storybook config files
|
|
247
254
|
],
|
|
248
255
|
});
|
|
249
256
|
//# sourceMappingURL=eslint.config.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eslint.config.js","sourceRoot":"","sources":["../src/eslint.config.js"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,MAAM,CAAC;AAExB,OAAO,YAAY,MAAM,sBAAsB,CAAC;AAChD,OAAO,aAAa,MAAM,wBAAwB,CAAC;AACnD,OAAO,mBAAmB,MAAM,6BAA6B,CAAC;AAC9D,OAAO,cAAc,MAAM,wBAAwB,CAAC;AACpD,OAAO,WAAW,MAAM,
|
|
1
|
+
{"version":3,"file":"eslint.config.js","sourceRoot":"","sources":["../src/eslint.config.js"],"names":[],"mappings":"AAAA,OAAO,IA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|
-
'boolean-prop-naming': import("eslint").Rule.RuleModule;
|
|
14
|
-
'button-has-type': import("eslint").Rule.RuleModule;
|
|
15
|
-
'checked-requires-onchange-or-readonly': import("eslint").Rule.RuleModule;
|
|
16
|
-
'default-props-match-prop-types': import("eslint").Rule.RuleModule;
|
|
17
|
-
'destructuring-assignment': import("eslint").Rule.RuleModule;
|
|
18
|
-
'display-name': import("eslint").Rule.RuleModule;
|
|
19
|
-
'forbid-component-props': import("eslint").Rule.RuleModule;
|
|
20
|
-
'forbid-dom-props': import("eslint").Rule.RuleModule;
|
|
21
|
-
'forbid-elements': import("eslint").Rule.RuleModule;
|
|
22
|
-
'forbid-foreign-prop-types': import("eslint").Rule.RuleModule;
|
|
23
|
-
'forbid-prop-types': import("eslint").Rule.RuleModule;
|
|
24
|
-
'forward-ref-uses-ref': import("eslint").Rule.RuleModule;
|
|
25
|
-
'function-component-definition': import("eslint").Rule.RuleModule;
|
|
26
|
-
'hook-use-state': import("eslint").Rule.RuleModule;
|
|
27
|
-
'iframe-missing-sandbox': import("eslint").Rule.RuleModule;
|
|
28
|
-
'jsx-boolean-value': import("eslint").Rule.RuleModule;
|
|
29
|
-
'jsx-child-element-spacing': import("eslint").Rule.RuleModule;
|
|
30
|
-
'jsx-closing-bracket-location': import("eslint").Rule.RuleModule;
|
|
31
|
-
'jsx-closing-tag-location': import("eslint").Rule.RuleModule;
|
|
32
|
-
'jsx-curly-spacing': import("eslint").Rule.RuleModule;
|
|
33
|
-
'jsx-curly-newline': import("eslint").Rule.RuleModule;
|
|
34
|
-
'jsx-equals-spacing': import("eslint").Rule.RuleModule;
|
|
35
|
-
'jsx-filename-extension': import("eslint").Rule.RuleModule;
|
|
36
|
-
'jsx-first-prop-new-line': import("eslint").Rule.RuleModule;
|
|
37
|
-
'jsx-handler-names': import("eslint").Rule.RuleModule;
|
|
38
|
-
'jsx-indent': import("eslint").Rule.RuleModule;
|
|
39
|
-
'jsx-indent-props': import("eslint").Rule.RuleModule;
|
|
40
|
-
'jsx-key': import("eslint").Rule.RuleModule;
|
|
41
|
-
'jsx-max-depth': import("eslint").Rule.RuleModule;
|
|
42
|
-
'jsx-max-props-per-line': import("eslint").Rule.RuleModule;
|
|
43
|
-
'jsx-newline': import("eslint").Rule.RuleModule;
|
|
44
|
-
'jsx-no-bind': import("eslint").Rule.RuleModule;
|
|
45
|
-
'jsx-no-comment-textnodes': import("eslint").Rule.RuleModule;
|
|
46
|
-
'jsx-no-constructed-context-values': import("eslint").Rule.RuleModule;
|
|
47
|
-
'jsx-no-duplicate-props': import("eslint").Rule.RuleModule;
|
|
48
|
-
'jsx-no-leaked-render': import("eslint").Rule.RuleModule;
|
|
49
|
-
'jsx-no-literals': import("eslint").Rule.RuleModule;
|
|
50
|
-
'jsx-no-script-url': import("eslint").Rule.RuleModule;
|
|
51
|
-
'jsx-no-target-blank': import("eslint").Rule.RuleModule;
|
|
52
|
-
'jsx-no-useless-fragment': import("eslint").Rule.RuleModule;
|
|
53
|
-
'jsx-one-expression-per-line': import("eslint").Rule.RuleModule;
|
|
54
|
-
'jsx-no-undef': import("eslint").Rule.RuleModule;
|
|
55
|
-
'jsx-curly-brace-presence': import("eslint").Rule.RuleModule;
|
|
56
|
-
'jsx-pascal-case': import("eslint").Rule.RuleModule;
|
|
57
|
-
'jsx-fragments': import("eslint").Rule.RuleModule;
|
|
58
|
-
'jsx-props-no-multi-spaces': import("eslint").Rule.RuleModule;
|
|
59
|
-
'jsx-props-no-spreading': import("eslint").Rule.RuleModule;
|
|
60
|
-
'jsx-props-no-spread-multi': import("eslint").Rule.RuleModule;
|
|
61
|
-
'jsx-sort-default-props': import("eslint").Rule.RuleModule;
|
|
62
|
-
'jsx-sort-props': import("eslint").Rule.RuleModule;
|
|
63
|
-
'jsx-space-before-closing': import("eslint").Rule.RuleModule;
|
|
64
|
-
'jsx-tag-spacing': import("eslint").Rule.RuleModule;
|
|
65
|
-
'jsx-uses-react': import("eslint").Rule.RuleModule;
|
|
66
|
-
'jsx-uses-vars': import("eslint").Rule.RuleModule;
|
|
67
|
-
'jsx-wrap-multilines': import("eslint").Rule.RuleModule;
|
|
68
|
-
'no-invalid-html-attribute': import("eslint").Rule.RuleModule;
|
|
69
|
-
'no-access-state-in-setstate': import("eslint").Rule.RuleModule;
|
|
70
|
-
'no-adjacent-inline-elements': import("eslint").Rule.RuleModule;
|
|
71
|
-
'no-array-index-key': import("eslint").Rule.RuleModule;
|
|
72
|
-
'no-arrow-function-lifecycle': import("eslint").Rule.RuleModule;
|
|
73
|
-
'no-children-prop': import("eslint").Rule.RuleModule;
|
|
74
|
-
'no-danger': import("eslint").Rule.RuleModule;
|
|
75
|
-
'no-danger-with-children': import("eslint").Rule.RuleModule;
|
|
76
|
-
'no-deprecated': import("eslint").Rule.RuleModule;
|
|
77
|
-
'no-did-mount-set-state': import("eslint").Rule.RuleModule;
|
|
78
|
-
'no-did-update-set-state': import("eslint").Rule.RuleModule;
|
|
79
|
-
'no-direct-mutation-state': import("eslint").Rule.RuleModule;
|
|
80
|
-
'no-find-dom-node': import("eslint").Rule.RuleModule;
|
|
81
|
-
'no-is-mounted': import("eslint").Rule.RuleModule;
|
|
82
|
-
'no-multi-comp': import("eslint").Rule.RuleModule;
|
|
83
|
-
'no-namespace': import("eslint").Rule.RuleModule;
|
|
84
|
-
'no-set-state': import("eslint").Rule.RuleModule;
|
|
85
|
-
'no-string-refs': import("eslint").Rule.RuleModule;
|
|
86
|
-
'no-redundant-should-component-update': import("eslint").Rule.RuleModule;
|
|
87
|
-
'no-render-return-value': import("eslint").Rule.RuleModule;
|
|
88
|
-
'no-this-in-sfc': import("eslint").Rule.RuleModule;
|
|
89
|
-
'no-typos': import("eslint").Rule.RuleModule;
|
|
90
|
-
'no-unescaped-entities': import("eslint").Rule.RuleModule;
|
|
91
|
-
'no-unknown-property': import("eslint").Rule.RuleModule;
|
|
92
|
-
'no-unsafe': import("eslint").Rule.RuleModule;
|
|
93
|
-
'no-unstable-nested-components': import("eslint").Rule.RuleModule;
|
|
94
|
-
'no-unused-class-component-methods': import("eslint").Rule.RuleModule;
|
|
95
|
-
'no-unused-prop-types': import("eslint").Rule.RuleModule;
|
|
96
|
-
'no-unused-state': import("eslint").Rule.RuleModule;
|
|
97
|
-
'no-object-type-as-default-prop': import("eslint").Rule.RuleModule;
|
|
98
|
-
'no-will-update-set-state': import("eslint").Rule.RuleModule;
|
|
99
|
-
'prefer-es6-class': import("eslint").Rule.RuleModule;
|
|
100
|
-
'prefer-exact-props': import("eslint").Rule.RuleModule;
|
|
101
|
-
'prefer-read-only-props': import("eslint").Rule.RuleModule;
|
|
102
|
-
'prefer-stateless-function': import("eslint").Rule.RuleModule;
|
|
103
|
-
'prop-types': import("eslint").Rule.RuleModule;
|
|
104
|
-
'react-in-jsx-scope': import("eslint").Rule.RuleModule;
|
|
105
|
-
'require-default-props': import("eslint").Rule.RuleModule;
|
|
106
|
-
'require-optimization': import("eslint").Rule.RuleModule;
|
|
107
|
-
'require-render-return': import("eslint").Rule.RuleModule;
|
|
108
|
-
'self-closing-comp': import("eslint").Rule.RuleModule;
|
|
109
|
-
'sort-comp': import("eslint").Rule.RuleModule;
|
|
110
|
-
'sort-default-props': import("eslint").Rule.RuleModule;
|
|
111
|
-
'sort-prop-types': import("eslint").Rule.RuleModule;
|
|
112
|
-
'state-in-constructor': import("eslint").Rule.RuleModule;
|
|
113
|
-
'static-property-placement': import("eslint").Rule.RuleModule;
|
|
114
|
-
'style-prop-object': import("eslint").Rule.RuleModule;
|
|
115
|
-
'void-dom-elements-no-children': import("eslint").Rule.RuleModule;
|
|
116
|
-
}>;
|
|
117
|
-
rules: {
|
|
118
|
-
'boolean-prop-naming': import("eslint").Rule.RuleModule;
|
|
119
|
-
'button-has-type': import("eslint").Rule.RuleModule;
|
|
120
|
-
'checked-requires-onchange-or-readonly': import("eslint").Rule.RuleModule;
|
|
121
|
-
'default-props-match-prop-types': import("eslint").Rule.RuleModule;
|
|
122
|
-
'destructuring-assignment': import("eslint").Rule.RuleModule;
|
|
123
|
-
'display-name': import("eslint").Rule.RuleModule;
|
|
124
|
-
'forbid-component-props': import("eslint").Rule.RuleModule;
|
|
125
|
-
'forbid-dom-props': import("eslint").Rule.RuleModule;
|
|
126
|
-
'forbid-elements': import("eslint").Rule.RuleModule;
|
|
127
|
-
'forbid-foreign-prop-types': import("eslint").Rule.RuleModule;
|
|
128
|
-
'forbid-prop-types': import("eslint").Rule.RuleModule;
|
|
129
|
-
'forward-ref-uses-ref': import("eslint").Rule.RuleModule;
|
|
130
|
-
'function-component-definition': import("eslint").Rule.RuleModule;
|
|
131
|
-
'hook-use-state': import("eslint").Rule.RuleModule;
|
|
132
|
-
'iframe-missing-sandbox': import("eslint").Rule.RuleModule;
|
|
133
|
-
'jsx-boolean-value': import("eslint").Rule.RuleModule;
|
|
134
|
-
'jsx-child-element-spacing': import("eslint").Rule.RuleModule;
|
|
135
|
-
'jsx-closing-bracket-location': import("eslint").Rule.RuleModule;
|
|
136
|
-
'jsx-closing-tag-location': import("eslint").Rule.RuleModule;
|
|
137
|
-
'jsx-curly-spacing': import("eslint").Rule.RuleModule;
|
|
138
|
-
'jsx-curly-newline': import("eslint").Rule.RuleModule;
|
|
139
|
-
'jsx-equals-spacing': import("eslint").Rule.RuleModule;
|
|
140
|
-
'jsx-filename-extension': import("eslint").Rule.RuleModule;
|
|
141
|
-
'jsx-first-prop-new-line': import("eslint").Rule.RuleModule;
|
|
142
|
-
'jsx-handler-names': import("eslint").Rule.RuleModule;
|
|
143
|
-
'jsx-indent': import("eslint").Rule.RuleModule;
|
|
144
|
-
'jsx-indent-props': import("eslint").Rule.RuleModule;
|
|
145
|
-
'jsx-key': import("eslint").Rule.RuleModule;
|
|
146
|
-
'jsx-max-depth': import("eslint").Rule.RuleModule;
|
|
147
|
-
'jsx-max-props-per-line': import("eslint").Rule.RuleModule;
|
|
148
|
-
'jsx-newline': import("eslint").Rule.RuleModule;
|
|
149
|
-
'jsx-no-bind': import("eslint").Rule.RuleModule;
|
|
150
|
-
'jsx-no-comment-textnodes': import("eslint").Rule.RuleModule;
|
|
151
|
-
'jsx-no-constructed-context-values': import("eslint").Rule.RuleModule;
|
|
152
|
-
'jsx-no-duplicate-props': import("eslint").Rule.RuleModule;
|
|
153
|
-
'jsx-no-leaked-render': import("eslint").Rule.RuleModule;
|
|
154
|
-
'jsx-no-literals': import("eslint").Rule.RuleModule;
|
|
155
|
-
'jsx-no-script-url': import("eslint").Rule.RuleModule;
|
|
156
|
-
'jsx-no-target-blank': import("eslint").Rule.RuleModule;
|
|
157
|
-
'jsx-no-useless-fragment': import("eslint").Rule.RuleModule;
|
|
158
|
-
'jsx-one-expression-per-line': import("eslint").Rule.RuleModule;
|
|
159
|
-
'jsx-no-undef': import("eslint").Rule.RuleModule;
|
|
160
|
-
'jsx-curly-brace-presence': import("eslint").Rule.RuleModule;
|
|
161
|
-
'jsx-pascal-case': import("eslint").Rule.RuleModule;
|
|
162
|
-
'jsx-fragments': import("eslint").Rule.RuleModule;
|
|
163
|
-
'jsx-props-no-multi-spaces': import("eslint").Rule.RuleModule;
|
|
164
|
-
'jsx-props-no-spreading': import("eslint").Rule.RuleModule;
|
|
165
|
-
'jsx-props-no-spread-multi': import("eslint").Rule.RuleModule;
|
|
166
|
-
'jsx-sort-default-props': import("eslint").Rule.RuleModule;
|
|
167
|
-
'jsx-sort-props': import("eslint").Rule.RuleModule;
|
|
168
|
-
'jsx-space-before-closing': import("eslint").Rule.RuleModule;
|
|
169
|
-
'jsx-tag-spacing': import("eslint").Rule.RuleModule;
|
|
170
|
-
'jsx-uses-react': import("eslint").Rule.RuleModule;
|
|
171
|
-
'jsx-uses-vars': import("eslint").Rule.RuleModule;
|
|
172
|
-
'jsx-wrap-multilines': import("eslint").Rule.RuleModule;
|
|
173
|
-
'no-invalid-html-attribute': import("eslint").Rule.RuleModule;
|
|
174
|
-
'no-access-state-in-setstate': import("eslint").Rule.RuleModule;
|
|
175
|
-
'no-adjacent-inline-elements': import("eslint").Rule.RuleModule;
|
|
176
|
-
'no-array-index-key': import("eslint").Rule.RuleModule;
|
|
177
|
-
'no-arrow-function-lifecycle': import("eslint").Rule.RuleModule;
|
|
178
|
-
'no-children-prop': import("eslint").Rule.RuleModule;
|
|
179
|
-
'no-danger': import("eslint").Rule.RuleModule;
|
|
180
|
-
'no-danger-with-children': import("eslint").Rule.RuleModule;
|
|
181
|
-
'no-deprecated': import("eslint").Rule.RuleModule;
|
|
182
|
-
'no-did-mount-set-state': import("eslint").Rule.RuleModule;
|
|
183
|
-
'no-did-update-set-state': import("eslint").Rule.RuleModule;
|
|
184
|
-
'no-direct-mutation-state': import("eslint").Rule.RuleModule;
|
|
185
|
-
'no-find-dom-node': import("eslint").Rule.RuleModule;
|
|
186
|
-
'no-is-mounted': import("eslint").Rule.RuleModule;
|
|
187
|
-
'no-multi-comp': import("eslint").Rule.RuleModule;
|
|
188
|
-
'no-namespace': import("eslint").Rule.RuleModule;
|
|
189
|
-
'no-set-state': import("eslint").Rule.RuleModule;
|
|
190
|
-
'no-string-refs': import("eslint").Rule.RuleModule;
|
|
191
|
-
'no-redundant-should-component-update': import("eslint").Rule.RuleModule;
|
|
192
|
-
'no-render-return-value': import("eslint").Rule.RuleModule;
|
|
193
|
-
'no-this-in-sfc': import("eslint").Rule.RuleModule;
|
|
194
|
-
'no-typos': import("eslint").Rule.RuleModule;
|
|
195
|
-
'no-unescaped-entities': import("eslint").Rule.RuleModule;
|
|
196
|
-
'no-unknown-property': import("eslint").Rule.RuleModule;
|
|
197
|
-
'no-unsafe': import("eslint").Rule.RuleModule;
|
|
198
|
-
'no-unstable-nested-components': import("eslint").Rule.RuleModule;
|
|
199
|
-
'no-unused-class-component-methods': import("eslint").Rule.RuleModule;
|
|
200
|
-
'no-unused-prop-types': import("eslint").Rule.RuleModule;
|
|
201
|
-
'no-unused-state': import("eslint").Rule.RuleModule;
|
|
202
|
-
'no-object-type-as-default-prop': import("eslint").Rule.RuleModule;
|
|
203
|
-
'no-will-update-set-state': import("eslint").Rule.RuleModule;
|
|
204
|
-
'prefer-es6-class': import("eslint").Rule.RuleModule;
|
|
205
|
-
'prefer-exact-props': import("eslint").Rule.RuleModule;
|
|
206
|
-
'prefer-read-only-props': import("eslint").Rule.RuleModule;
|
|
207
|
-
'prefer-stateless-function': import("eslint").Rule.RuleModule;
|
|
208
|
-
'prop-types': import("eslint").Rule.RuleModule;
|
|
209
|
-
'react-in-jsx-scope': import("eslint").Rule.RuleModule;
|
|
210
|
-
'require-default-props': import("eslint").Rule.RuleModule;
|
|
211
|
-
'require-optimization': import("eslint").Rule.RuleModule;
|
|
212
|
-
'require-render-return': import("eslint").Rule.RuleModule;
|
|
213
|
-
'self-closing-comp': import("eslint").Rule.RuleModule;
|
|
214
|
-
'sort-comp': import("eslint").Rule.RuleModule;
|
|
215
|
-
'sort-default-props': import("eslint").Rule.RuleModule;
|
|
216
|
-
'sort-prop-types': import("eslint").Rule.RuleModule;
|
|
217
|
-
'state-in-constructor': import("eslint").Rule.RuleModule;
|
|
218
|
-
'static-property-placement': import("eslint").Rule.RuleModule;
|
|
219
|
-
'style-prop-object': import("eslint").Rule.RuleModule;
|
|
220
|
-
'void-dom-elements-no-children': import("eslint").Rule.RuleModule;
|
|
221
|
-
};
|
|
222
|
-
configs: {
|
|
223
|
-
recommended: {
|
|
224
|
-
plugins: ["react"];
|
|
225
|
-
parserOptions: {
|
|
226
|
-
ecmaFeatures: {
|
|
227
|
-
jsx: boolean;
|
|
228
|
-
};
|
|
229
|
-
};
|
|
230
|
-
rules: {
|
|
231
|
-
"react/display-name": 2;
|
|
232
|
-
"react/jsx-key": 2;
|
|
233
|
-
"react/jsx-no-comment-textnodes": 2;
|
|
234
|
-
"react/jsx-no-duplicate-props": 2;
|
|
235
|
-
"react/jsx-no-target-blank": 2;
|
|
236
|
-
"react/jsx-no-undef": 2;
|
|
237
|
-
"react/jsx-uses-react": 2;
|
|
238
|
-
"react/jsx-uses-vars": 2;
|
|
239
|
-
"react/no-children-prop": 2;
|
|
240
|
-
"react/no-danger-with-children": 2;
|
|
241
|
-
"react/no-deprecated": 2;
|
|
242
|
-
"react/no-direct-mutation-state": 2;
|
|
243
|
-
"react/no-find-dom-node": 2;
|
|
244
|
-
"react/no-is-mounted": 2;
|
|
245
|
-
"react/no-render-return-value": 2;
|
|
246
|
-
"react/no-string-refs": 2;
|
|
247
|
-
"react/no-unescaped-entities": 2;
|
|
248
|
-
"react/no-unknown-property": 2;
|
|
249
|
-
"react/no-unsafe": 0;
|
|
250
|
-
"react/prop-types": 2;
|
|
251
|
-
"react/react-in-jsx-scope": 2;
|
|
252
|
-
"react/require-render-return": 2;
|
|
253
|
-
};
|
|
254
|
-
};
|
|
255
|
-
all: {
|
|
256
|
-
plugins: ["react"];
|
|
257
|
-
parserOptions: {
|
|
258
|
-
ecmaFeatures: {
|
|
259
|
-
jsx: boolean;
|
|
260
|
-
};
|
|
261
|
-
};
|
|
262
|
-
rules: Record<"boolean-prop-naming" | "button-has-type" | "checked-requires-onchange-or-readonly" | "default-props-match-prop-types" | "destructuring-assignment" | "display-name" | "forbid-component-props" | "forbid-dom-props" | "forbid-elements" | "forbid-foreign-prop-types" | "forbid-prop-types" | "prop-types" | "forward-ref-uses-ref" | "function-component-definition" | "hook-use-state" | "iframe-missing-sandbox" | "jsx-boolean-value" | "jsx-child-element-spacing" | "jsx-closing-bracket-location" | "jsx-closing-tag-location" | "jsx-curly-spacing" | "jsx-curly-newline" | "jsx-equals-spacing" | "jsx-filename-extension" | "jsx-first-prop-new-line" | "jsx-handler-names" | "jsx-indent" | "jsx-indent-props" | "jsx-key" | "jsx-max-depth" | "jsx-max-props-per-line" | "jsx-newline" | "jsx-no-bind" | "jsx-no-comment-textnodes" | "jsx-no-constructed-context-values" | "jsx-no-duplicate-props" | "jsx-no-leaked-render" | "jsx-no-literals" | "jsx-no-script-url" | "jsx-no-target-blank" | "jsx-no-useless-fragment" | "jsx-one-expression-per-line" | "jsx-no-undef" | "jsx-curly-brace-presence" | "jsx-pascal-case" | "jsx-fragments" | "jsx-props-no-multi-spaces" | "jsx-props-no-spreading" | "jsx-props-no-spread-multi" | "sort-default-props" | "jsx-sort-default-props" | "jsx-sort-props" | "jsx-tag-spacing" | "jsx-space-before-closing" | "jsx-uses-react" | "jsx-uses-vars" | "jsx-wrap-multilines" | "no-invalid-html-attribute" | "no-access-state-in-setstate" | "no-adjacent-inline-elements" | "no-array-index-key" | "no-arrow-function-lifecycle" | "no-children-prop" | "no-danger" | "no-danger-with-children" | "no-deprecated" | "no-direct-mutation-state" | "no-find-dom-node" | "no-is-mounted" | "no-multi-comp" | "no-namespace" | "no-set-state" | "no-string-refs" | "no-redundant-should-component-update" | "no-render-return-value" | "no-this-in-sfc" | "no-typos" | "no-unescaped-entities" | "no-unknown-property" | "no-unsafe" | "no-unstable-nested-components" | "no-unused-class-component-methods" | "no-unused-prop-types" | "no-unused-state" | "no-object-type-as-default-prop" | "prefer-es6-class" | "prefer-exact-props" | "prefer-read-only-props" | "prefer-stateless-function" | "react-in-jsx-scope" | "require-default-props" | "require-optimization" | "require-render-return" | "self-closing-comp" | "sort-comp" | "sort-prop-types" | "state-in-constructor" | "static-property-placement" | "style-prop-object" | "void-dom-elements-no-children" | "no-did-mount-set-state" | "no-did-update-set-state" | "no-will-update-set-state", 2 | "error">;
|
|
263
|
-
};
|
|
264
|
-
'jsx-runtime': {
|
|
265
|
-
plugins: ["react"];
|
|
266
|
-
parserOptions: {
|
|
267
|
-
ecmaFeatures: {
|
|
268
|
-
jsx: boolean;
|
|
269
|
-
};
|
|
270
|
-
jsxPragma: any;
|
|
271
|
-
};
|
|
272
|
-
rules: {
|
|
273
|
-
"react/react-in-jsx-scope": 0;
|
|
274
|
-
"react/jsx-uses-react": 0;
|
|
275
|
-
};
|
|
276
|
-
};
|
|
277
|
-
flat: Record<string, reactPlugin.ReactFlatConfig>;
|
|
278
|
-
} & {
|
|
279
|
-
flat: Record<string, reactPlugin.ReactFlatConfig>;
|
|
280
|
-
};
|
|
281
|
-
};
|
|
282
|
-
"react-hooks": {
|
|
283
|
-
meta: {
|
|
284
|
-
name: string;
|
|
285
|
-
version: string;
|
|
286
|
-
};
|
|
287
|
-
rules: {
|
|
288
|
-
"exhaustive-deps": {
|
|
289
|
-
meta: {
|
|
290
|
-
type: "suggestion";
|
|
291
|
-
docs: {
|
|
292
|
-
description: string;
|
|
293
|
-
recommended: true;
|
|
294
|
-
url: string;
|
|
295
|
-
};
|
|
296
|
-
fixable: "code";
|
|
297
|
-
hasSuggestions: true;
|
|
298
|
-
schema: {
|
|
299
|
-
type: "object";
|
|
300
|
-
additionalProperties: false;
|
|
301
|
-
enableDangerousAutofixThisMayCauseInfiniteLoops: boolean;
|
|
302
|
-
properties: {
|
|
303
|
-
additionalHooks: {
|
|
304
|
-
type: "string";
|
|
305
|
-
};
|
|
306
|
-
enableDangerousAutofixThisMayCauseInfiniteLoops: {
|
|
307
|
-
type: "boolean";
|
|
308
|
-
};
|
|
309
|
-
experimental_autoDependenciesHooks: {
|
|
310
|
-
type: "array";
|
|
311
|
-
items: {
|
|
312
|
-
type: "string";
|
|
313
|
-
};
|
|
314
|
-
};
|
|
315
|
-
requireExplicitEffectDeps: {
|
|
316
|
-
type: "boolean";
|
|
317
|
-
};
|
|
318
|
-
};
|
|
319
|
-
}[];
|
|
320
|
-
};
|
|
321
|
-
create(context: import("eslint").Rule.RuleContext): {
|
|
322
|
-
CallExpression: (node: import("estree").CallExpression) => void;
|
|
323
|
-
};
|
|
324
|
-
};
|
|
325
|
-
"rules-of-hooks": {
|
|
326
|
-
meta: {
|
|
327
|
-
type: "problem";
|
|
328
|
-
docs: {
|
|
329
|
-
description: string;
|
|
330
|
-
recommended: true;
|
|
331
|
-
url: string;
|
|
332
|
-
};
|
|
333
|
-
schema: {
|
|
334
|
-
type: "object";
|
|
335
|
-
additionalProperties: false;
|
|
336
|
-
properties: {
|
|
337
|
-
additionalHooks: {
|
|
338
|
-
type: "string";
|
|
339
|
-
};
|
|
340
|
-
};
|
|
341
|
-
}[];
|
|
342
|
-
};
|
|
343
|
-
create(context: import("eslint").Rule.RuleContext): {
|
|
344
|
-
"*"(node: any): void;
|
|
345
|
-
"*:exit"(node: any): void;
|
|
346
|
-
CallExpression(node: import("estree").CallExpression & import("eslint").Rule.NodeParentExtension): void;
|
|
347
|
-
Identifier(node: import("estree").Identifier & import("eslint").Rule.NodeParentExtension): void;
|
|
348
|
-
"CallExpression:exit"(node: import("estree").CallExpression & import("eslint").Rule.NodeParentExtension): void;
|
|
349
|
-
FunctionDeclaration(node: import("estree").FunctionDeclaration & import("eslint").Rule.NodeParentExtension): void;
|
|
350
|
-
ArrowFunctionExpression(node: import("estree").ArrowFunctionExpression & import("eslint").Rule.NodeParentExtension): void;
|
|
351
|
-
};
|
|
352
|
-
};
|
|
353
|
-
};
|
|
354
|
-
configs: {
|
|
355
|
-
recommended: {
|
|
356
|
-
plugins: string[];
|
|
357
|
-
rules: import("eslint").Linter.RulesRecord;
|
|
358
|
-
};
|
|
359
|
-
"recommended-latest": {
|
|
360
|
-
plugins: string[];
|
|
361
|
-
rules: import("eslint").Linter.RulesRecord;
|
|
362
|
-
};
|
|
363
|
-
flat: {
|
|
364
|
-
recommended: {
|
|
365
|
-
plugins: {
|
|
366
|
-
react: any;
|
|
367
|
-
};
|
|
368
|
-
rules: import("eslint").Linter.RulesRecord;
|
|
369
|
-
};
|
|
370
|
-
"recommended-latest": {
|
|
371
|
-
plugins: {
|
|
372
|
-
react: any;
|
|
373
|
-
};
|
|
374
|
-
rules: import("eslint").Linter.RulesRecord;
|
|
375
|
-
};
|
|
376
|
-
};
|
|
377
|
-
};
|
|
378
|
-
};
|
|
379
|
-
import: import("@eslint/core", { with: { "resolution-mode": "require" } }).Plugin & {
|
|
380
|
-
meta: {
|
|
381
|
-
name: string;
|
|
382
|
-
version: string;
|
|
383
|
-
};
|
|
384
|
-
configs: {
|
|
385
|
-
"recommended": import("eslint").Linter.LegacyConfig;
|
|
386
|
-
"errors": import("eslint").Linter.LegacyConfig;
|
|
387
|
-
"warnings": import("eslint").Linter.LegacyConfig;
|
|
388
|
-
"stage-0": import("eslint").Linter.LegacyConfig;
|
|
389
|
-
"react": import("eslint").Linter.LegacyConfig;
|
|
390
|
-
"react-native": import("eslint").Linter.LegacyConfig;
|
|
391
|
-
"electron": import("eslint").Linter.LegacyConfig;
|
|
392
|
-
"typescript": import("eslint").Linter.LegacyConfig;
|
|
393
|
-
};
|
|
394
|
-
flatConfigs: {
|
|
395
|
-
"recommended": import("eslint").Linter.FlatConfig;
|
|
396
|
-
"errors": import("eslint").Linter.FlatConfig;
|
|
397
|
-
"warnings": import("eslint").Linter.FlatConfig;
|
|
398
|
-
"stage-0": import("eslint").Linter.FlatConfig;
|
|
399
|
-
"react": import("eslint").Linter.FlatConfig;
|
|
400
|
-
"react-native": import("eslint").Linter.FlatConfig;
|
|
401
|
-
"electron": import("eslint").Linter.FlatConfig;
|
|
402
|
-
"typescript": import("eslint").Linter.FlatConfig;
|
|
403
|
-
};
|
|
404
|
-
rules: {
|
|
405
|
-
[key: string]: import("eslint").Rule.RuleModule;
|
|
406
|
-
};
|
|
407
|
-
};
|
|
408
|
-
unicorn: import("@eslint/core", { with: { "resolution-mode": "require" } }).Plugin & {
|
|
409
|
-
configs: {
|
|
410
|
-
recommended: import("eslint").Linter.FlatConfig;
|
|
411
|
-
unopinionated: import("eslint").Linter.FlatConfig;
|
|
412
|
-
all: import("eslint").Linter.FlatConfig;
|
|
413
|
-
"flat/all": import("eslint").Linter.FlatConfig;
|
|
414
|
-
"flat/recommended": import("eslint").Linter.FlatConfig;
|
|
415
|
-
};
|
|
416
|
-
};
|
|
417
|
-
"@next/next": typeof nextPlugin;
|
|
418
|
-
"jsx-a11y": import("@eslint/core", { with: { "resolution-mode": "require" } }).Plugin & {
|
|
419
|
-
configs: {
|
|
420
|
-
recommended: import("eslint").Linter.LegacyConfig;
|
|
421
|
-
strict: import("eslint").Linter.LegacyConfig;
|
|
422
|
-
};
|
|
423
|
-
flatConfigs: {
|
|
424
|
-
recommended: import("eslint").Linter.Config;
|
|
425
|
-
strict: import("eslint").Linter.Config;
|
|
426
|
-
};
|
|
427
|
-
};
|
|
428
|
-
prettier: import("@eslint/core", { with: { "resolution-mode": "require" } }).Plugin;
|
|
429
|
-
"react-compiler": typeof reactCompilerPlugin;
|
|
430
|
-
};
|
|
10
|
+
plugins: any;
|
|
431
11
|
settings: {
|
|
432
12
|
"import/resolver": {
|
|
433
13
|
typescript: {
|
|
@@ -439,20 +19,16 @@ declare const config: ({
|
|
|
439
19
|
};
|
|
440
20
|
};
|
|
441
21
|
rules: {
|
|
442
|
-
"react/
|
|
443
|
-
"react/jsx-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
"react/
|
|
22
|
+
"@eslint-react/no-array-index-key": string;
|
|
23
|
+
"@eslint-react/jsx-shorthand-boolean": string;
|
|
24
|
+
"@eslint-react/no-unnecessary-use-prefix": string;
|
|
25
|
+
"@eslint-react/no-unused-props": string;
|
|
26
|
+
"@eslint-react/no-unused-state": string;
|
|
27
|
+
"@eslint-react/dom/no-void-elements-with-children": string;
|
|
28
|
+
"@eslint-react/naming-convention/filename-extension": (string | {
|
|
448
29
|
extensions: string[];
|
|
449
30
|
})[];
|
|
450
|
-
"react/no-array-index-key": string;
|
|
451
|
-
"react/no-unused-prop-types": string;
|
|
452
|
-
"react/no-unused-state": string;
|
|
453
|
-
"react/void-dom-elements-no-children": string;
|
|
454
31
|
"react-hooks/exhaustive-deps": string;
|
|
455
|
-
"react/no-object-type-as-default-prop": string;
|
|
456
32
|
"react-compiler/react-compiler": string;
|
|
457
33
|
"import/prefer-default-export": string;
|
|
458
34
|
"import/no-extraneous-dependencies": (string | {
|
|
@@ -500,8 +76,6 @@ declare const config: ({
|
|
|
500
76
|
})[];
|
|
501
77
|
curly: string[];
|
|
502
78
|
"prettier/prettier": string;
|
|
503
|
-
'react/react-in-jsx-scope': 0;
|
|
504
|
-
'react/jsx-uses-react': 0;
|
|
505
79
|
};
|
|
506
80
|
ignores?: undefined;
|
|
507
81
|
} | {
|
|
@@ -512,7 +86,4 @@ declare const config: ({
|
|
|
512
86
|
settings?: undefined;
|
|
513
87
|
rules?: undefined;
|
|
514
88
|
})[];
|
|
515
|
-
import reactPlugin from "eslint-plugin-react";
|
|
516
|
-
import nextPlugin from "@next/eslint-plugin-next";
|
|
517
|
-
import reactCompilerPlugin from "eslint-plugin-react-compiler";
|
|
518
89
|
//# sourceMappingURL=eslint.config.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eslint.config.d.ts","sourceRoot":"","sources":["../../src/legacy/eslint.config.js"],"names":[],"mappings":";AAUA
|
|
1
|
+
{"version":3,"file":"eslint.config.d.ts","sourceRoot":"","sources":["../../src/legacy/eslint.config.js"],"names":[],"mappings":";AAUA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAsIE"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import importPlugin from "eslint-plugin-import";
|
|
2
2
|
import jsxA11yPlugin from "eslint-plugin-jsx-a11y";
|
|
3
3
|
import prettierPlugin from "eslint-plugin-prettier";
|
|
4
|
-
import
|
|
4
|
+
import eslintReact from "@eslint-react/eslint-plugin";
|
|
5
5
|
import reactCompilerPlugin from "eslint-plugin-react-compiler";
|
|
6
6
|
import reactHooksPlugin from "eslint-plugin-react-hooks";
|
|
7
7
|
import unicornPlugin from "eslint-plugin-unicorn";
|
|
@@ -16,7 +16,11 @@ const config = [
|
|
|
16
16
|
},
|
|
17
17
|
},
|
|
18
18
|
plugins: {
|
|
19
|
-
react
|
|
19
|
+
// Spread plugins from @eslint-react/eslint-plugin recommended config
|
|
20
|
+
// This includes: @eslint-react, @eslint-react/dom, @eslint-react/web-api,
|
|
21
|
+
// @eslint-react/hooks-extra, @eslint-react/naming-convention
|
|
22
|
+
// @ts-expect-error - plugins property exists at runtime but not in types
|
|
23
|
+
...eslintReact.configs.recommended.plugins,
|
|
20
24
|
"react-hooks": reactHooksPlugin,
|
|
21
25
|
import: importPlugin,
|
|
22
26
|
unicorn: unicornPlugin,
|
|
@@ -37,27 +41,22 @@ const config = [
|
|
|
37
41
|
},
|
|
38
42
|
rules: {
|
|
39
43
|
// Include recommended rules
|
|
40
|
-
|
|
41
|
-
...reactPlugin.configs["jsx-runtime"].rules,
|
|
44
|
+
...eslintReact.configs.recommended.rules,
|
|
42
45
|
...reactHooksPlugin.configs.recommended.rules,
|
|
43
46
|
...jsxA11yPlugin.configs.recommended.rules,
|
|
44
47
|
...nextPlugin.configs.recommended.rules,
|
|
45
|
-
// React rules
|
|
46
|
-
"react/
|
|
47
|
-
"react/jsx-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
"react/
|
|
48
|
+
// React rules (using @eslint-react/eslint-plugin)
|
|
49
|
+
"@eslint-react/no-array-index-key": "error",
|
|
50
|
+
"@eslint-react/jsx-shorthand-boolean": "error",
|
|
51
|
+
"@eslint-react/no-unnecessary-use-prefix": "warn",
|
|
52
|
+
"@eslint-react/no-unused-props": "error",
|
|
53
|
+
"@eslint-react/no-unused-state": "error",
|
|
54
|
+
"@eslint-react/dom/no-void-elements-with-children": "error",
|
|
55
|
+
"@eslint-react/naming-convention/filename-extension": [
|
|
52
56
|
"error",
|
|
53
57
|
{ extensions: [".jsx", ".tsx"] },
|
|
54
58
|
],
|
|
55
|
-
"react/no-array-index-key": "error",
|
|
56
|
-
"react/no-unused-prop-types": "error",
|
|
57
|
-
"react/no-unused-state": "error",
|
|
58
|
-
"react/void-dom-elements-no-children": "error",
|
|
59
59
|
"react-hooks/exhaustive-deps": "error",
|
|
60
|
-
"react/no-object-type-as-default-prop": "error",
|
|
61
60
|
"react-compiler/react-compiler": "error",
|
|
62
61
|
"import/prefer-default-export": "off",
|
|
63
62
|
"import/no-extraneous-dependencies": [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eslint.config.js","sourceRoot":"","sources":["../../src/legacy/eslint.config.js"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,sBAAsB,CAAC;AAChD,OAAO,aAAa,MAAM,wBAAwB,CAAC;AACnD,OAAO,cAAc,MAAM,wBAAwB,CAAC;AACpD,OAAO,WAAW,MAAM,
|
|
1
|
+
{"version":3,"file":"eslint.config.js","sourceRoot":"","sources":["../../src/legacy/eslint.config.js"],"names":[],"mappings":"AAAA,OAAO,YAAY,MAAM,sBAAsB,CAAC;AAChD,OAAO,aAAa,MAAM,wBAAwB,CAAC;AACnD,OAAO,cAAc,MAAM,wBAAwB,CAAC;AACpD,OAAO,WAAW,MAAM,6BAA6B,CAAC;AACtD,OAAO,mBAAmB,MAAM,8BAA8B,CAAC;AAC/D,OAAO,gBAAgB,MAAM,2BAA2B,CAAC;AACzD,OAAO,aAAa,MAAM,uBAAuB,CAAC;AAElD,OAAO,UAAU,MAAM,0BAA0B,CAAC;AAElD,MAAM,MAAM,GAAG;IACb;QACE,KAAK,EAAE,CAAC,8BAA8B,CAAC;QACvC,eAAe,EAAE;YACf,UAAU,EAAE,QAAQ;YACpB,aAAa,EAAE;gBACb,OAAO,EAAE,iBAAiB;aAC3B;SACF;QACD,OAAO,EAAE;YACP,qEAAqE;YACrE,0EAA0E;YAC1E,6DAA6D;YAC7D,yEAAyE;YACzE,GAAG,WAAW,CAAC,OAAO,CAAC,WAAW,CAAC,OAAO;YAC1C,aAAa,EAAE,gBAAgB;YAC/B,MAAM,EAAE,YAAY;YACpB,OAAO,EAAE,aAAa;YACtB,YAAY,EAAE,UAAU;YACxB,UAAU,EAAE,aAAa;YACzB,QAAQ,EAAE,cAAc;YACxB,gBAAgB,EAAE,mBAAmB;SACtC;QACD,QAAQ,EAAE;YACR,iBAAiB,EAAE;gBACjB,UAAU,EAAE;oBACV,OAAO,EAAE,iBAAiB;iBAC3B;aACF;YACD,KAAK,EAAE;gBACL,OAAO,EAAE,QAAQ;aAClB;SACF;QACD,KAAK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O;YACpC,yBAAyB,EAAE,OAAO;YAElC,yBAAyB;YACzB,mCAAmC,EAAE,OAAO;YAC5C,2BAA2B,EAAE,OAAO;YACpC,mCAAmC,EAAE,OAAO;YAC5C,4BAA4B,EAAE,OAAO;YACrC,wCAAwC,EAAE,OAAO;YACjD,gCAAgC,EAAE,OAAO;YACzC,mCAAmC,EAAE,OAAO;YAC5C,+BAA+B,EAAE,OAAO;YACxC,qBAAqB,EAAE,OAAO;YAC9B,8BAA8B,EAAE,OAAO;YAEvC,cAAc;YACd,mBAAmB,EAAE,OAAO;YAC5B,4BAA4B,EAAE,MAAM;YACpC,uBAAuB,EAAE,OAAO;YAChC,uBAAuB,EAAE,OAAO;YAChC,gBAAgB,EAAE,OAAO;YACzB,sBAAsB,EAAE;gBACtB,OAAO;gBACP;oBACE,QAAQ,EAAE,gBAAgB;oBAC1B,OAAO,EACL,wKAAwK;iBAC3K;gBACD;oBACE,QAAQ,EAAE,kBAAkB;oBAC5B,OAAO,EACL,iGAAiG;iBACpG;gBACD;oBACE,QAAQ,EAAE,eAAe;oBACzB,OAAO,EACL,+FAA+F;iBAClG;aACF;YACD,YAAY,EAAE,CAAC,MAAM,EAAE,EAAE,KAAK,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,CAAC;YAC5D,KAAK,EAAE,CAAC,OAAO,EAAE,KAAK,CAAC;YAEvB,uBAAuB;YACvB,mBAAmB,EAAE,OAAO;SAC7B;KACF;IACD;QACE,OAAO,EAAE,CAAC,SAAS,EAAE,YAAY,EAAE,YAAY,EAAE,UAAU,CAAC;KAC7D;CACF,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@greenberry/linting-config",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.5",
|
|
4
4
|
"private": false,
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -24,17 +24,17 @@
|
|
|
24
24
|
"dist"
|
|
25
25
|
],
|
|
26
26
|
"dependencies": {
|
|
27
|
+
"@eslint-react/eslint-plugin": "^2.5.1",
|
|
27
28
|
"@ianvs/prettier-plugin-sort-imports": "^4.7.0",
|
|
28
29
|
"@next/eslint-plugin-next": "^16.1.1",
|
|
29
30
|
"@typescript-eslint/parser": "^8.52.0",
|
|
30
31
|
"eslint": "^9.39.2",
|
|
31
32
|
"eslint-config-prettier": "^10.1.8",
|
|
32
|
-
"eslint-import-resolver-typescript": "3.8.3",
|
|
33
|
+
"eslint-import-resolver-typescript": "^3.8.3",
|
|
33
34
|
"eslint-plugin-import": "2.32.0",
|
|
34
35
|
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
35
36
|
"eslint-plugin-perfectionist": "^5.3.0",
|
|
36
37
|
"eslint-plugin-prettier": "^5.5.4",
|
|
37
|
-
"eslint-plugin-react": "^7.37.5",
|
|
38
38
|
"eslint-plugin-react-compiler": "^19.1.0-rc.2",
|
|
39
39
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
40
40
|
"eslint-plugin-react-hooks-extra": "^2.5.1",
|