@eslint-react/eslint-plugin 1.52.9 → 1.52.10-beta.1

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/index.mjs CHANGED
@@ -1,466 +1,454 @@
1
- import reactDebug from 'eslint-plugin-react-debug';
2
- import reactDom from 'eslint-plugin-react-dom';
3
- import reactHooksExtra from 'eslint-plugin-react-hooks-extra';
4
- import reactNamingConvention from 'eslint-plugin-react-naming-convention';
5
- import reactWebApi from 'eslint-plugin-react-web-api';
6
- import react from 'eslint-plugin-react-x';
7
- import { DEFAULT_ESLINT_REACT_SETTINGS } from '@eslint-react/shared';
1
+ import { __export } from "./chunk-B9dir_RE.mjs";
2
+ import reactDebug from "eslint-plugin-react-debug";
3
+ import reactDom from "eslint-plugin-react-dom";
4
+ import reactHooksExtra from "eslint-plugin-react-hooks-extra";
5
+ import reactNamingConvention from "eslint-plugin-react-naming-convention";
6
+ import reactWebApi from "eslint-plugin-react-web-api";
7
+ import react from "eslint-plugin-react-x";
8
+ import { DEFAULT_ESLINT_REACT_SETTINGS } from "@eslint-react/shared";
8
9
 
9
- var __defProp = Object.defineProperty;
10
- var __export = (target, all) => {
11
- for (var name14 in all)
12
- __defProp(target, name14, { get: all[name14], enumerable: true });
13
- };
14
-
15
- // package.json
10
+ //#region package.json
16
11
  var name = "@eslint-react/eslint-plugin";
17
- var version = "1.52.9";
18
-
19
- // src/configs/all.ts
20
- var all_exports = {};
21
- __export(all_exports, {
22
- name: () => name4,
23
- plugins: () => plugins3,
24
- rules: () => rules3,
25
- settings: () => settings3
26
- });
12
+ var version = "1.52.10-beta.1";
27
13
 
28
- // src/configs/dom.ts
14
+ //#endregion
15
+ //#region src/configs/dom.ts
29
16
  var dom_exports = {};
30
17
  __export(dom_exports, {
31
- name: () => name2,
32
- plugins: () => plugins,
33
- rules: () => rules,
34
- settings: () => settings
18
+ name: () => name$12,
19
+ plugins: () => plugins$7,
20
+ rules: () => rules$8,
21
+ settings: () => settings$6
35
22
  });
36
- var name2 = "@eslint-react/dom";
37
- var rules = {
38
- "@eslint-react/dom/no-dangerously-set-innerhtml": "warn",
39
- "@eslint-react/dom/no-dangerously-set-innerhtml-with-children": "error",
40
- "@eslint-react/dom/no-find-dom-node": "error",
41
- "@eslint-react/dom/no-flush-sync": "error",
42
- "@eslint-react/dom/no-hydrate": "error",
43
- "@eslint-react/dom/no-missing-button-type": "warn",
44
- "@eslint-react/dom/no-missing-iframe-sandbox": "warn",
45
- "@eslint-react/dom/no-namespace": "error",
46
- "@eslint-react/dom/no-render": "error",
47
- "@eslint-react/dom/no-render-return-value": "error",
48
- "@eslint-react/dom/no-script-url": "warn",
49
- "@eslint-react/dom/no-unsafe-iframe-sandbox": "warn",
50
- "@eslint-react/dom/no-unsafe-target-blank": "warn",
51
- "@eslint-react/dom/no-use-form-state": "error",
52
- "@eslint-react/dom/no-void-elements-with-children": "error"
53
- };
54
- var plugins = {
55
- "@eslint-react/dom": reactDom
56
- };
57
- var settings = {
58
- "react-x": DEFAULT_ESLINT_REACT_SETTINGS
23
+ const name$12 = "@eslint-react/dom";
24
+ const rules$8 = {
25
+ "@eslint-react/dom/no-dangerously-set-innerhtml": "warn",
26
+ "@eslint-react/dom/no-dangerously-set-innerhtml-with-children": "error",
27
+ "@eslint-react/dom/no-find-dom-node": "error",
28
+ "@eslint-react/dom/no-flush-sync": "error",
29
+ "@eslint-react/dom/no-hydrate": "error",
30
+ "@eslint-react/dom/no-missing-button-type": "warn",
31
+ "@eslint-react/dom/no-missing-iframe-sandbox": "warn",
32
+ "@eslint-react/dom/no-namespace": "error",
33
+ "@eslint-react/dom/no-render": "error",
34
+ "@eslint-react/dom/no-render-return-value": "error",
35
+ "@eslint-react/dom/no-script-url": "warn",
36
+ "@eslint-react/dom/no-unsafe-iframe-sandbox": "warn",
37
+ "@eslint-react/dom/no-unsafe-target-blank": "warn",
38
+ "@eslint-react/dom/no-use-form-state": "error",
39
+ "@eslint-react/dom/no-void-elements-with-children": "error"
59
40
  };
41
+ const plugins$7 = { "@eslint-react/dom": reactDom };
42
+ const settings$6 = { "react-x": DEFAULT_ESLINT_REACT_SETTINGS };
60
43
 
61
- // src/configs/x.ts
44
+ //#endregion
45
+ //#region src/configs/x.ts
62
46
  var x_exports = {};
63
47
  __export(x_exports, {
64
- name: () => name3,
65
- plugins: () => plugins2,
66
- rules: () => rules2,
67
- settings: () => settings2
48
+ name: () => name$11,
49
+ plugins: () => plugins$6,
50
+ rules: () => rules$12,
51
+ settings: () => settings$5
68
52
  });
69
- var name3 = "@eslint-react/x";
70
- var rules2 = {
71
- "@eslint-react/jsx-key-before-spread": "warn",
72
- "@eslint-react/jsx-no-duplicate-props": "warn",
73
- "@eslint-react/jsx-uses-react": "warn",
74
- "@eslint-react/jsx-uses-vars": "warn",
75
- "@eslint-react/no-access-state-in-setstate": "error",
76
- "@eslint-react/no-array-index-key": "warn",
77
- "@eslint-react/no-children-count": "warn",
78
- "@eslint-react/no-children-for-each": "warn",
79
- "@eslint-react/no-children-map": "warn",
80
- "@eslint-react/no-children-only": "warn",
81
- "@eslint-react/no-children-to-array": "warn",
82
- "@eslint-react/no-clone-element": "warn",
83
- "@eslint-react/no-comment-textnodes": "warn",
84
- "@eslint-react/no-component-will-mount": "error",
85
- "@eslint-react/no-component-will-receive-props": "error",
86
- "@eslint-react/no-component-will-update": "error",
87
- "@eslint-react/no-context-provider": "warn",
88
- "@eslint-react/no-create-ref": "error",
89
- "@eslint-react/no-default-props": "error",
90
- "@eslint-react/no-direct-mutation-state": "error",
91
- "@eslint-react/no-duplicate-key": "warn",
92
- "@eslint-react/no-forward-ref": "warn",
93
- "@eslint-react/no-implicit-key": "warn",
94
- "@eslint-react/no-missing-key": "error",
95
- "@eslint-react/no-misused-capture-owner-stack": "error",
96
- "@eslint-react/no-nested-component-definitions": "error",
97
- "@eslint-react/no-nested-lazy-component-declarations": "warn",
98
- "@eslint-react/no-prop-types": "error",
99
- "@eslint-react/no-redundant-should-component-update": "error",
100
- "@eslint-react/no-set-state-in-component-did-mount": "warn",
101
- "@eslint-react/no-set-state-in-component-did-update": "warn",
102
- "@eslint-react/no-set-state-in-component-will-update": "warn",
103
- "@eslint-react/no-string-refs": "error",
104
- "@eslint-react/no-unsafe-component-will-mount": "warn",
105
- "@eslint-react/no-unsafe-component-will-receive-props": "warn",
106
- "@eslint-react/no-unsafe-component-will-update": "warn",
107
- "@eslint-react/no-unstable-context-value": "warn",
108
- "@eslint-react/no-unstable-default-props": "warn",
109
- "@eslint-react/no-unused-class-component-members": "warn",
110
- "@eslint-react/no-unused-state": "warn",
111
- "@eslint-react/no-use-context": "warn",
112
- "@eslint-react/no-useless-forward-ref": "warn"
113
- };
114
- var plugins2 = {
115
- "@eslint-react": react
116
- };
117
- var settings2 = {
118
- "react-x": DEFAULT_ESLINT_REACT_SETTINGS
53
+ const name$11 = "@eslint-react/x";
54
+ const rules$12 = {
55
+ "@eslint-react/jsx-key-before-spread": "warn",
56
+ "@eslint-react/jsx-no-duplicate-props": "warn",
57
+ "@eslint-react/jsx-uses-react": "warn",
58
+ "@eslint-react/jsx-uses-vars": "warn",
59
+ "@eslint-react/no-access-state-in-setstate": "error",
60
+ "@eslint-react/no-array-index-key": "warn",
61
+ "@eslint-react/no-children-count": "warn",
62
+ "@eslint-react/no-children-for-each": "warn",
63
+ "@eslint-react/no-children-map": "warn",
64
+ "@eslint-react/no-children-only": "warn",
65
+ "@eslint-react/no-children-to-array": "warn",
66
+ "@eslint-react/no-clone-element": "warn",
67
+ "@eslint-react/no-comment-textnodes": "warn",
68
+ "@eslint-react/no-component-will-mount": "error",
69
+ "@eslint-react/no-component-will-receive-props": "error",
70
+ "@eslint-react/no-component-will-update": "error",
71
+ "@eslint-react/no-context-provider": "warn",
72
+ "@eslint-react/no-create-ref": "error",
73
+ "@eslint-react/no-default-props": "error",
74
+ "@eslint-react/no-direct-mutation-state": "error",
75
+ "@eslint-react/no-duplicate-key": "warn",
76
+ "@eslint-react/no-forward-ref": "warn",
77
+ "@eslint-react/no-implicit-key": "warn",
78
+ "@eslint-react/no-missing-key": "error",
79
+ "@eslint-react/no-misused-capture-owner-stack": "error",
80
+ "@eslint-react/no-nested-component-definitions": "error",
81
+ "@eslint-react/no-nested-lazy-component-declarations": "warn",
82
+ "@eslint-react/no-prop-types": "error",
83
+ "@eslint-react/no-redundant-should-component-update": "error",
84
+ "@eslint-react/no-set-state-in-component-did-mount": "warn",
85
+ "@eslint-react/no-set-state-in-component-did-update": "warn",
86
+ "@eslint-react/no-set-state-in-component-will-update": "warn",
87
+ "@eslint-react/no-string-refs": "error",
88
+ "@eslint-react/no-unsafe-component-will-mount": "warn",
89
+ "@eslint-react/no-unsafe-component-will-receive-props": "warn",
90
+ "@eslint-react/no-unsafe-component-will-update": "warn",
91
+ "@eslint-react/no-unstable-context-value": "warn",
92
+ "@eslint-react/no-unstable-default-props": "warn",
93
+ "@eslint-react/no-unused-class-component-members": "warn",
94
+ "@eslint-react/no-unused-state": "warn",
95
+ "@eslint-react/no-use-context": "warn",
96
+ "@eslint-react/no-useless-forward-ref": "warn"
119
97
  };
98
+ const plugins$6 = { "@eslint-react": react };
99
+ const settings$5 = { "react-x": DEFAULT_ESLINT_REACT_SETTINGS };
120
100
 
121
- // src/configs/all.ts
122
- var name4 = "@eslint-react/all";
123
- var rules3 = {
124
- "@eslint-react/avoid-shorthand-boolean": "warn",
125
- "@eslint-react/avoid-shorthand-fragment": "warn",
126
- "@eslint-react/jsx-key-before-spread": "warn",
127
- "@eslint-react/jsx-no-duplicate-props": "warn",
128
- "@eslint-react/jsx-no-iife": "warn",
129
- "@eslint-react/jsx-no-undef": "error",
130
- "@eslint-react/jsx-uses-react": "warn",
131
- "@eslint-react/jsx-uses-vars": "warn",
132
- "@eslint-react/no-access-state-in-setstate": "error",
133
- "@eslint-react/no-array-index-key": "warn",
134
- "@eslint-react/no-children-count": "warn",
135
- "@eslint-react/no-children-for-each": "warn",
136
- "@eslint-react/no-children-map": "warn",
137
- "@eslint-react/no-children-only": "warn",
138
- "@eslint-react/no-children-prop": "warn",
139
- "@eslint-react/no-children-to-array": "warn",
140
- "@eslint-react/no-class-component": "warn",
141
- "@eslint-react/no-clone-element": "warn",
142
- "@eslint-react/no-comment-textnodes": "warn",
143
- "@eslint-react/no-complex-conditional-rendering": "warn",
144
- "@eslint-react/no-component-will-mount": "error",
145
- "@eslint-react/no-component-will-receive-props": "error",
146
- "@eslint-react/no-component-will-update": "error",
147
- "@eslint-react/no-context-provider": "warn",
148
- "@eslint-react/no-create-ref": "error",
149
- "@eslint-react/no-default-props": "error",
150
- "@eslint-react/no-direct-mutation-state": "error",
151
- "@eslint-react/no-duplicate-key": "warn",
152
- "@eslint-react/no-forward-ref": "warn",
153
- "@eslint-react/no-implicit-key": "warn",
154
- // "@eslint-react/no-leaked-conditional-rendering": "warn",
155
- "@eslint-react/no-missing-component-display-name": "warn",
156
- "@eslint-react/no-missing-context-display-name": "warn",
157
- "@eslint-react/no-missing-key": "error",
158
- "@eslint-react/no-misused-capture-owner-stack": "error",
159
- "@eslint-react/no-nested-component-definitions": "error",
160
- "@eslint-react/no-nested-lazy-component-declarations": "warn",
161
- "@eslint-react/no-prop-types": "error",
162
- "@eslint-react/no-redundant-should-component-update": "error",
163
- "@eslint-react/no-set-state-in-component-did-mount": "warn",
164
- "@eslint-react/no-set-state-in-component-did-update": "warn",
165
- "@eslint-react/no-set-state-in-component-will-update": "warn",
166
- "@eslint-react/no-string-refs": "error",
167
- "@eslint-react/no-unsafe-component-will-mount": "warn",
168
- "@eslint-react/no-unsafe-component-will-receive-props": "warn",
169
- "@eslint-react/no-unsafe-component-will-update": "warn",
170
- "@eslint-react/no-unstable-context-value": "warn",
171
- "@eslint-react/no-unstable-default-props": "warn",
172
- "@eslint-react/no-unused-class-component-members": "warn",
173
- "@eslint-react/no-unused-state": "warn",
174
- "@eslint-react/no-use-context": "warn",
175
- "@eslint-react/no-useless-forward-ref": "warn",
176
- "@eslint-react/no-useless-fragment": "warn",
177
- "@eslint-react/prefer-destructuring-assignment": "warn",
178
- "@eslint-react/prefer-react-namespace-import": "warn",
179
- // "@eslint-react/prefer-read-only-props": "warn",
180
- "@eslint-react/prefer-shorthand-boolean": "off",
181
- "@eslint-react/prefer-shorthand-fragment": "off",
182
- "@eslint-react/dom/no-dangerously-set-innerhtml": "warn",
183
- "@eslint-react/dom/no-dangerously-set-innerhtml-with-children": "error",
184
- "@eslint-react/dom/no-find-dom-node": "error",
185
- "@eslint-react/dom/no-flush-sync": "error",
186
- "@eslint-react/dom/no-hydrate": "error",
187
- "@eslint-react/dom/no-missing-button-type": "warn",
188
- "@eslint-react/dom/no-missing-iframe-sandbox": "warn",
189
- "@eslint-react/dom/no-namespace": "error",
190
- "@eslint-react/dom/no-render": "error",
191
- "@eslint-react/dom/no-render-return-value": "error",
192
- "@eslint-react/dom/no-script-url": "warn",
193
- "@eslint-react/dom/no-unknown-property": "warn",
194
- "@eslint-react/dom/no-unsafe-iframe-sandbox": "warn",
195
- "@eslint-react/dom/no-unsafe-target-blank": "warn",
196
- "@eslint-react/dom/no-use-form-state": "error",
197
- "@eslint-react/dom/no-void-elements-with-children": "error",
198
- "@eslint-react/web-api/no-leaked-event-listener": "warn",
199
- "@eslint-react/web-api/no-leaked-interval": "warn",
200
- "@eslint-react/web-api/no-leaked-resize-observer": "warn",
201
- "@eslint-react/web-api/no-leaked-timeout": "warn",
202
- "@eslint-react/hooks-extra/no-direct-set-state-in-use-effect": "warn",
203
- "@eslint-react/hooks-extra/no-direct-set-state-in-use-layout-effect": "warn",
204
- "@eslint-react/hooks-extra/no-unnecessary-use-callback": "warn",
205
- "@eslint-react/hooks-extra/no-unnecessary-use-memo": "warn",
206
- "@eslint-react/hooks-extra/no-unnecessary-use-prefix": "warn",
207
- "@eslint-react/hooks-extra/prefer-use-state-lazy-initialization": "warn",
208
- "@eslint-react/naming-convention/component-name": "warn",
209
- "@eslint-react/naming-convention/context-name": "warn",
210
- "@eslint-react/naming-convention/filename": "warn",
211
- "@eslint-react/naming-convention/filename-extension": "warn",
212
- "@eslint-react/naming-convention/use-state": "warn"
213
- };
214
- var plugins3 = {
215
- ...plugins2,
216
- ...plugins,
217
- "@eslint-react/debug": reactDebug,
218
- "@eslint-react/hooks-extra": reactHooksExtra,
219
- "@eslint-react/naming-convention": reactNamingConvention,
220
- "@eslint-react/web-api": reactWebApi
101
+ //#endregion
102
+ //#region src/configs/all.ts
103
+ var all_exports = {};
104
+ __export(all_exports, {
105
+ name: () => name$10,
106
+ plugins: () => plugins$5,
107
+ rules: () => rules$3,
108
+ settings: () => settings$4
109
+ });
110
+ const name$10 = "@eslint-react/all";
111
+ const rules$3 = {
112
+ "@eslint-react/avoid-shorthand-boolean": "warn",
113
+ "@eslint-react/avoid-shorthand-fragment": "warn",
114
+ "@eslint-react/jsx-key-before-spread": "warn",
115
+ "@eslint-react/jsx-no-duplicate-props": "warn",
116
+ "@eslint-react/jsx-no-iife": "warn",
117
+ "@eslint-react/jsx-no-undef": "error",
118
+ "@eslint-react/jsx-uses-react": "warn",
119
+ "@eslint-react/jsx-uses-vars": "warn",
120
+ "@eslint-react/no-access-state-in-setstate": "error",
121
+ "@eslint-react/no-array-index-key": "warn",
122
+ "@eslint-react/no-children-count": "warn",
123
+ "@eslint-react/no-children-for-each": "warn",
124
+ "@eslint-react/no-children-map": "warn",
125
+ "@eslint-react/no-children-only": "warn",
126
+ "@eslint-react/no-children-prop": "warn",
127
+ "@eslint-react/no-children-to-array": "warn",
128
+ "@eslint-react/no-class-component": "warn",
129
+ "@eslint-react/no-clone-element": "warn",
130
+ "@eslint-react/no-comment-textnodes": "warn",
131
+ "@eslint-react/no-complex-conditional-rendering": "warn",
132
+ "@eslint-react/no-component-will-mount": "error",
133
+ "@eslint-react/no-component-will-receive-props": "error",
134
+ "@eslint-react/no-component-will-update": "error",
135
+ "@eslint-react/no-context-provider": "warn",
136
+ "@eslint-react/no-create-ref": "error",
137
+ "@eslint-react/no-default-props": "error",
138
+ "@eslint-react/no-direct-mutation-state": "error",
139
+ "@eslint-react/no-duplicate-key": "warn",
140
+ "@eslint-react/no-forward-ref": "warn",
141
+ "@eslint-react/no-implicit-key": "warn",
142
+ "@eslint-react/no-missing-component-display-name": "warn",
143
+ "@eslint-react/no-missing-context-display-name": "warn",
144
+ "@eslint-react/no-missing-key": "error",
145
+ "@eslint-react/no-misused-capture-owner-stack": "error",
146
+ "@eslint-react/no-nested-component-definitions": "error",
147
+ "@eslint-react/no-nested-lazy-component-declarations": "warn",
148
+ "@eslint-react/no-prop-types": "error",
149
+ "@eslint-react/no-redundant-should-component-update": "error",
150
+ "@eslint-react/no-set-state-in-component-did-mount": "warn",
151
+ "@eslint-react/no-set-state-in-component-did-update": "warn",
152
+ "@eslint-react/no-set-state-in-component-will-update": "warn",
153
+ "@eslint-react/no-string-refs": "error",
154
+ "@eslint-react/no-unsafe-component-will-mount": "warn",
155
+ "@eslint-react/no-unsafe-component-will-receive-props": "warn",
156
+ "@eslint-react/no-unsafe-component-will-update": "warn",
157
+ "@eslint-react/no-unstable-context-value": "warn",
158
+ "@eslint-react/no-unstable-default-props": "warn",
159
+ "@eslint-react/no-unused-class-component-members": "warn",
160
+ "@eslint-react/no-unused-state": "warn",
161
+ "@eslint-react/no-use-context": "warn",
162
+ "@eslint-react/no-useless-forward-ref": "warn",
163
+ "@eslint-react/no-useless-fragment": "warn",
164
+ "@eslint-react/prefer-destructuring-assignment": "warn",
165
+ "@eslint-react/prefer-react-namespace-import": "warn",
166
+ "@eslint-react/prefer-shorthand-boolean": "off",
167
+ "@eslint-react/prefer-shorthand-fragment": "off",
168
+ "@eslint-react/dom/no-dangerously-set-innerhtml": "warn",
169
+ "@eslint-react/dom/no-dangerously-set-innerhtml-with-children": "error",
170
+ "@eslint-react/dom/no-find-dom-node": "error",
171
+ "@eslint-react/dom/no-flush-sync": "error",
172
+ "@eslint-react/dom/no-hydrate": "error",
173
+ "@eslint-react/dom/no-missing-button-type": "warn",
174
+ "@eslint-react/dom/no-missing-iframe-sandbox": "warn",
175
+ "@eslint-react/dom/no-namespace": "error",
176
+ "@eslint-react/dom/no-render": "error",
177
+ "@eslint-react/dom/no-render-return-value": "error",
178
+ "@eslint-react/dom/no-script-url": "warn",
179
+ "@eslint-react/dom/no-unknown-property": "warn",
180
+ "@eslint-react/dom/no-unsafe-iframe-sandbox": "warn",
181
+ "@eslint-react/dom/no-unsafe-target-blank": "warn",
182
+ "@eslint-react/dom/no-use-form-state": "error",
183
+ "@eslint-react/dom/no-void-elements-with-children": "error",
184
+ "@eslint-react/web-api/no-leaked-event-listener": "warn",
185
+ "@eslint-react/web-api/no-leaked-interval": "warn",
186
+ "@eslint-react/web-api/no-leaked-resize-observer": "warn",
187
+ "@eslint-react/web-api/no-leaked-timeout": "warn",
188
+ "@eslint-react/hooks-extra/no-direct-set-state-in-use-effect": "warn",
189
+ "@eslint-react/hooks-extra/no-direct-set-state-in-use-layout-effect": "warn",
190
+ "@eslint-react/hooks-extra/no-unnecessary-use-callback": "warn",
191
+ "@eslint-react/hooks-extra/no-unnecessary-use-memo": "warn",
192
+ "@eslint-react/hooks-extra/no-unnecessary-use-prefix": "warn",
193
+ "@eslint-react/hooks-extra/prefer-use-state-lazy-initialization": "warn",
194
+ "@eslint-react/naming-convention/component-name": "warn",
195
+ "@eslint-react/naming-convention/context-name": "warn",
196
+ "@eslint-react/naming-convention/filename": "warn",
197
+ "@eslint-react/naming-convention/filename-extension": "warn",
198
+ "@eslint-react/naming-convention/use-state": "warn"
221
199
  };
222
- var settings3 = {
223
- ...settings
200
+ const plugins$5 = {
201
+ ...plugins$6,
202
+ ...plugins$7,
203
+ "@eslint-react/debug": reactDebug,
204
+ "@eslint-react/hooks-extra": reactHooksExtra,
205
+ "@eslint-react/naming-convention": reactNamingConvention,
206
+ "@eslint-react/web-api": reactWebApi
224
207
  };
208
+ const settings$4 = { ...settings$6 };
225
209
 
226
- // src/configs/debug.ts
210
+ //#endregion
211
+ //#region src/configs/debug.ts
227
212
  var debug_exports = {};
228
213
  __export(debug_exports, {
229
- name: () => name5,
230
- plugins: () => plugins4,
231
- rules: () => rules4
214
+ name: () => name$9,
215
+ plugins: () => plugins$4,
216
+ rules: () => rules$10
232
217
  });
233
- var name5 = "@eslint-react/debug";
234
- var rules4 = {
235
- "@eslint-react/debug/class-component": "warn",
236
- "@eslint-react/debug/function-component": "warn",
237
- "@eslint-react/debug/hook": "warn",
238
- "@eslint-react/debug/is-from-react": "warn",
239
- "@eslint-react/debug/jsx": "warn"
240
- };
241
- var plugins4 = {
242
- "@eslint-react/debug": reactDebug
218
+ const name$9 = "@eslint-react/debug";
219
+ const rules$10 = {
220
+ "@eslint-react/debug/class-component": "warn",
221
+ "@eslint-react/debug/function-component": "warn",
222
+ "@eslint-react/debug/hook": "warn",
223
+ "@eslint-react/debug/is-from-react": "warn",
224
+ "@eslint-react/debug/jsx": "warn"
243
225
  };
226
+ const plugins$4 = { "@eslint-react/debug": reactDebug };
244
227
 
245
- // src/configs/disable-debug.ts
228
+ //#endregion
229
+ //#region src/configs/disable-debug.ts
246
230
  var disable_debug_exports = {};
247
231
  __export(disable_debug_exports, {
248
- name: () => name6,
249
- rules: () => rules5
232
+ name: () => name$8,
233
+ rules: () => rules$11
250
234
  });
251
- var name6 = "@eslint-react/disable-debug";
252
- var rules5 = Object.fromEntries(Object.entries(rules4).map(([rule]) => [rule, "off"]));
235
+ const name$8 = "@eslint-react/disable-debug";
236
+ const rules$11 = Object.fromEntries(Object.entries(rules$10).map(([rule]) => [rule, "off"]));
253
237
 
254
- // src/configs/disable-dom.ts
238
+ //#endregion
239
+ //#region src/configs/disable-dom.ts
255
240
  var disable_dom_exports = {};
256
241
  __export(disable_dom_exports, {
257
- name: () => name7,
258
- rules: () => rules6
242
+ name: () => name$7,
243
+ rules: () => rules$9
259
244
  });
260
- var name7 = "@eslint-react/disable-dom";
261
- var rules6 = Object.fromEntries(Object.entries(rules).map(([key]) => [key, "off"]));
245
+ const name$7 = "@eslint-react/disable-dom";
246
+ const rules$9 = Object.fromEntries(Object.entries(rules$8).map(([key]) => [key, "off"]));
262
247
 
263
- // src/configs/disable-type-checked.ts
248
+ //#endregion
249
+ //#region src/configs/disable-type-checked.ts
264
250
  var disable_type_checked_exports = {};
265
251
  __export(disable_type_checked_exports, {
266
- name: () => name8,
267
- rules: () => rules7
252
+ name: () => name$6,
253
+ rules: () => rules$4
268
254
  });
269
- var name8 = "@eslint-react/disable-type-checked";
270
- var rules7 = {
271
- "@eslint-react/no-leaked-conditional-rendering": "off",
272
- "@eslint-react/prefer-read-only-props": "off"
255
+ const name$6 = "@eslint-react/disable-type-checked";
256
+ const rules$4 = {
257
+ "@eslint-react/no-leaked-conditional-rendering": "off",
258
+ "@eslint-react/prefer-read-only-props": "off"
259
+ };
260
+
261
+ //#endregion
262
+ //#region src/configs/web-api.ts
263
+ const rules$6 = {
264
+ "@eslint-react/web-api/no-leaked-event-listener": "warn",
265
+ "@eslint-react/web-api/no-leaked-interval": "warn",
266
+ "@eslint-react/web-api/no-leaked-resize-observer": "warn",
267
+ "@eslint-react/web-api/no-leaked-timeout": "warn"
273
268
  };
269
+ const plugins$3 = { "@eslint-react/web-api": reactWebApi };
270
+ const settings$3 = { ...settings$6 };
274
271
 
275
- // src/configs/disable-web-api.ts
272
+ //#endregion
273
+ //#region src/configs/disable-web-api.ts
276
274
  var disable_web_api_exports = {};
277
275
  __export(disable_web_api_exports, {
278
- name: () => name9,
279
- rules: () => rules9
276
+ name: () => name$5,
277
+ rules: () => rules$7
280
278
  });
281
- var rules8 = {
282
- "@eslint-react/web-api/no-leaked-event-listener": "warn",
283
- "@eslint-react/web-api/no-leaked-interval": "warn",
284
- "@eslint-react/web-api/no-leaked-resize-observer": "warn",
285
- "@eslint-react/web-api/no-leaked-timeout": "warn"
286
- };
287
- var plugins5 = {
288
- "@eslint-react/web-api": reactWebApi
289
- };
290
-
291
- // src/configs/disable-web-api.ts
292
- var name9 = "@eslint-react/disable-web-api";
293
- var rules9 = Object.fromEntries(Object.entries(rules8).map(([key]) => [key, "off"]));
279
+ const name$5 = "@eslint-react/disable-web-api";
280
+ const rules$7 = Object.fromEntries(Object.entries(rules$6).map(([key]) => [key, "off"]));
294
281
 
295
- // src/configs/off.ts
282
+ //#endregion
283
+ //#region src/configs/off.ts
296
284
  var off_exports = {};
297
285
  __export(off_exports, {
298
- name: () => name10,
299
- rules: () => rules10
286
+ name: () => name$4,
287
+ rules: () => rules$5
300
288
  });
301
- var name10 = "@eslint-react/off";
302
- var rules10 = {
303
- ...Object.fromEntries(Object.entries(rules3).map(([key]) => [key, "off"])),
304
- ...rules7
289
+ const name$4 = "@eslint-react/off";
290
+ const rules$5 = {
291
+ ...Object.fromEntries(Object.entries(rules$3).map(([key]) => [key, "off"])),
292
+ ...rules$4
305
293
  };
306
294
 
307
- // src/configs/recommended.ts
295
+ //#endregion
296
+ //#region src/configs/recommended.ts
308
297
  var recommended_exports = {};
309
298
  __export(recommended_exports, {
310
- name: () => name11,
311
- plugins: () => plugins6,
312
- rules: () => rules11,
313
- settings: () => settings5
299
+ name: () => name$3,
300
+ plugins: () => plugins$2,
301
+ rules: () => rules$2,
302
+ settings: () => settings$2
314
303
  });
315
- var name11 = "@eslint-react/recommended";
316
- var rules11 = {
317
- ...rules2,
318
- ...rules,
319
- ...rules8,
320
- "@eslint-react/hooks-extra/no-direct-set-state-in-use-effect": "warn",
321
- "@eslint-react/hooks-extra/no-unnecessary-use-prefix": "warn",
322
- "@eslint-react/hooks-extra/prefer-use-state-lazy-initialization": "warn",
323
- "@eslint-react/naming-convention/context-name": "warn"
324
- // "@eslint-react/naming-convention/use-state": "warn",
304
+ const name$3 = "@eslint-react/recommended";
305
+ const rules$2 = {
306
+ ...rules$12,
307
+ ...rules$8,
308
+ ...rules$6,
309
+ "@eslint-react/hooks-extra/no-direct-set-state-in-use-effect": "warn",
310
+ "@eslint-react/hooks-extra/no-unnecessary-use-prefix": "warn",
311
+ "@eslint-react/hooks-extra/prefer-use-state-lazy-initialization": "warn",
312
+ "@eslint-react/naming-convention/context-name": "warn"
325
313
  };
326
- var plugins6 = {
327
- ...plugins2,
328
- ...plugins,
329
- ...plugins5,
330
- "@eslint-react/debug": reactDebug,
331
- "@eslint-react/hooks-extra": reactHooksExtra,
332
- "@eslint-react/naming-convention": reactNamingConvention
314
+ const plugins$2 = {
315
+ ...plugins$6,
316
+ ...plugins$7,
317
+ ...plugins$3,
318
+ "@eslint-react/debug": reactDebug,
319
+ "@eslint-react/hooks-extra": reactHooksExtra,
320
+ "@eslint-react/naming-convention": reactNamingConvention
333
321
  };
334
- var settings5 = {
335
- ...settings
336
- };
337
-
338
- // src/configs/recommended-type-checked.ts
339
- var recommended_type_checked_exports = {};
340
- __export(recommended_type_checked_exports, {
341
- name: () => name13,
342
- plugins: () => plugins8,
343
- rules: () => rules13,
344
- settings: () => settings7
345
- });
322
+ const settings$2 = { ...settings$6 };
346
323
 
347
- // src/configs/recommended-typescript.ts
324
+ //#endregion
325
+ //#region src/configs/recommended-typescript.ts
348
326
  var recommended_typescript_exports = {};
349
327
  __export(recommended_typescript_exports, {
350
- name: () => name12,
351
- plugins: () => plugins7,
352
- rules: () => rules12,
353
- settings: () => settings6
328
+ name: () => name$2,
329
+ plugins: () => plugins$1,
330
+ rules: () => rules$1,
331
+ settings: () => settings$1
354
332
  });
355
- var name12 = "@eslint-react/recommended-typescript";
356
- var rules12 = {
357
- ...rules11,
358
- "@eslint-react/dom/no-unknown-property": "off",
359
- "@eslint-react/jsx-no-duplicate-props": "off",
360
- "@eslint-react/jsx-uses-react": "off",
361
- "@eslint-react/jsx-uses-vars": "off"
362
- };
363
- var plugins7 = {
364
- ...plugins6
365
- };
366
- var settings6 = {
367
- ...settings5
333
+ const name$2 = "@eslint-react/recommended-typescript";
334
+ const rules$1 = {
335
+ ...rules$2,
336
+ "@eslint-react/dom/no-unknown-property": "off",
337
+ "@eslint-react/jsx-no-duplicate-props": "off",
338
+ "@eslint-react/jsx-uses-react": "off",
339
+ "@eslint-react/jsx-uses-vars": "off"
368
340
  };
341
+ const plugins$1 = { ...plugins$2 };
342
+ const settings$1 = { ...settings$2 };
369
343
 
370
- // src/configs/recommended-type-checked.ts
371
- var name13 = "@eslint-react/recommended-type-checked";
372
- var rules13 = {
373
- ...rules12,
374
- "@eslint-react/no-leaked-conditional-rendering": "warn"
375
- // "@eslint-react/prefer-read-only-props": "warn",
376
- };
377
- var plugins8 = {
378
- ...plugins7
379
- };
380
- var settings7 = {
381
- ...settings6
344
+ //#endregion
345
+ //#region src/configs/recommended-type-checked.ts
346
+ var recommended_type_checked_exports = {};
347
+ __export(recommended_type_checked_exports, {
348
+ name: () => name$1,
349
+ plugins: () => plugins,
350
+ rules: () => rules,
351
+ settings: () => settings
352
+ });
353
+ const name$1 = "@eslint-react/recommended-type-checked";
354
+ const rules = {
355
+ ...rules$1,
356
+ "@eslint-react/no-leaked-conditional-rendering": "warn"
382
357
  };
358
+ const plugins = { ...plugins$1 };
359
+ const settings = { ...settings$1 };
383
360
 
384
- // src/utils/type-of.ts
361
+ //#endregion
362
+ //#region src/utils/type-of.ts
363
+ /**
364
+ * This is an enhanced version of the typeof operator to check the type of more complex values.
365
+ * In this case we just mind about arrays and objects. We can add more on demand.
366
+ * @param t the value to be checked
367
+ * @returns the type of the value
368
+ */
385
369
  function typeOf(t) {
386
- return Object.prototype.toString.call(t).replace(/^\[object (.+)\]$/, "$1").toLowerCase();
370
+ return Object.prototype.toString.call(t).replace(/^\[object (.+)\]$/, "$1").toLowerCase();
387
371
  }
388
372
 
389
- // src/utils/transform-keys.ts
373
+ //#endregion
374
+ //#region src/utils/transform-keys.ts
375
+ /**
376
+ * This function is used to shallowly transform the keys of an object.
377
+ * It will only be transformed at runtime, so it's not type safe.
378
+ * @param obj the object to transform.
379
+ * @param transform the function to transform the keys from string to string.
380
+ * @returns the transformed object.
381
+ * @example transformKeys({ 'foo-bar': { 'fizz-buzz': true } }, camelCase)
382
+ * // { fooBar: { 'fizz-buzz': true } }
383
+ */
390
384
  function transformKeys(obj, transform) {
391
- if (typeOf(obj) !== "object") {
392
- return obj;
393
- }
394
- const res = {};
395
- for (const key in obj) {
396
- res[transform(key)] = obj[key];
397
- }
398
- return res;
385
+ if (typeOf(obj) !== "object") return obj;
386
+ const res = {};
387
+ for (const key in obj) res[transform(key)] = obj[key];
388
+ return res;
399
389
  }
400
390
 
401
- // src/utils/pad-keys-left.ts
391
+ //#endregion
392
+ //#region src/utils/pad-keys-left.ts
402
393
  function padKeysLeft(obj, left) {
403
- return transformKeys(obj, (key) => `${left}${key}`);
394
+ return transformKeys(obj, (key) => `${left}${key}`);
404
395
  }
405
396
 
406
- // src/index.ts
407
- function toLegacyConfig({ rules: rules14 }) {
408
- return {
409
- plugins: ["@eslint-react"],
410
- rules: rules14
411
- };
397
+ //#endregion
398
+ //#region src/index.ts
399
+ function toLegacyConfig({ rules: rules$13 }) {
400
+ return {
401
+ plugins: ["@eslint-react"],
402
+ rules: rules$13
403
+ };
412
404
  }
413
- var plugin = {
414
- meta: {
415
- name,
416
- version
417
- },
418
- rules: {
419
- ...react.rules,
420
- ...padKeysLeft(reactDom.rules, "dom/"),
421
- ...padKeysLeft(reactWebApi.rules, "web-api/"),
422
- ...padKeysLeft(reactHooksExtra.rules, "hooks-extra/"),
423
- ...padKeysLeft(reactNamingConvention.rules, "naming-convention/"),
424
- ...padKeysLeft(reactDebug.rules, "debug/")
425
- }
405
+ const plugin = {
406
+ meta: {
407
+ name,
408
+ version
409
+ },
410
+ rules: {
411
+ ...react.rules,
412
+ ...padKeysLeft(reactDom.rules, "dom/"),
413
+ ...padKeysLeft(reactWebApi.rules, "web-api/"),
414
+ ...padKeysLeft(reactHooksExtra.rules, "hooks-extra/"),
415
+ ...padKeysLeft(reactNamingConvention.rules, "naming-convention/"),
416
+ ...padKeysLeft(reactDebug.rules, "debug/")
417
+ }
426
418
  };
427
- var index_default = {
428
- ...plugin,
429
- configs: {
430
- ["all"]: all_exports,
431
- ["all-legacy"]: toLegacyConfig(all_exports),
432
- ["debug"]: debug_exports,
433
- ["debug-legacy"]: toLegacyConfig(debug_exports),
434
- ["disable-debug"]: disable_debug_exports,
435
- ["disable-debug-legacy"]: toLegacyConfig(disable_debug_exports),
436
- ["disable-dom"]: disable_dom_exports,
437
- ["disable-dom-legacy"]: toLegacyConfig(disable_dom_exports),
438
- ["disable-type-checked"]: disable_type_checked_exports,
439
- ["disable-type-checked-legacy"]: toLegacyConfig(disable_type_checked_exports),
440
- ["disable-web-api"]: disable_web_api_exports,
441
- ["disable-web-api-legacy"]: toLegacyConfig(disable_web_api_exports),
442
- ["dom"]: dom_exports,
443
- ["dom-legacy"]: toLegacyConfig(dom_exports),
444
- ["off"]: off_exports,
445
- ["off-legacy"]: toLegacyConfig(off_exports),
446
- ["recommended"]: recommended_exports,
447
- ["recommended-legacy"]: toLegacyConfig(recommended_exports),
448
- ["recommended-type-checked"]: recommended_type_checked_exports,
449
- ["recommended-type-checked-legacy"]: toLegacyConfig(recommended_type_checked_exports),
450
- ["recommended-typescript"]: recommended_typescript_exports,
451
- ["recommended-typescript-legacy"]: toLegacyConfig(recommended_typescript_exports),
452
- ["x"]: x_exports,
453
- ["x-legacy"]: toLegacyConfig(x_exports),
454
- // Part: deprecated presets
455
- /** @deprecated Use `x` instead */
456
- ["core"]: x_exports,
457
- /** @deprecated Use `x-legacy` instead */
458
- ["core-legacy"]: toLegacyConfig(x_exports),
459
- /** @deprecated Use `disable-dom` instead */
460
- ["off-dom"]: disable_dom_exports,
461
- /** @deprecated Use `disable-dom-legacy` instead */
462
- ["off-dom-legacy"]: toLegacyConfig(disable_dom_exports)
463
- }
419
+ var src_default = {
420
+ ...plugin,
421
+ configs: {
422
+ ["all"]: all_exports,
423
+ ["all-legacy"]: toLegacyConfig(all_exports),
424
+ ["debug"]: debug_exports,
425
+ ["debug-legacy"]: toLegacyConfig(debug_exports),
426
+ ["disable-debug"]: disable_debug_exports,
427
+ ["disable-debug-legacy"]: toLegacyConfig(disable_debug_exports),
428
+ ["disable-dom"]: disable_dom_exports,
429
+ ["disable-dom-legacy"]: toLegacyConfig(disable_dom_exports),
430
+ ["disable-type-checked"]: disable_type_checked_exports,
431
+ ["disable-type-checked-legacy"]: toLegacyConfig(disable_type_checked_exports),
432
+ ["disable-web-api"]: disable_web_api_exports,
433
+ ["disable-web-api-legacy"]: toLegacyConfig(disable_web_api_exports),
434
+ ["dom"]: dom_exports,
435
+ ["dom-legacy"]: toLegacyConfig(dom_exports),
436
+ ["off"]: off_exports,
437
+ ["off-legacy"]: toLegacyConfig(off_exports),
438
+ ["recommended"]: recommended_exports,
439
+ ["recommended-legacy"]: toLegacyConfig(recommended_exports),
440
+ ["recommended-type-checked"]: recommended_type_checked_exports,
441
+ ["recommended-type-checked-legacy"]: toLegacyConfig(recommended_type_checked_exports),
442
+ ["recommended-typescript"]: recommended_typescript_exports,
443
+ ["recommended-typescript-legacy"]: toLegacyConfig(recommended_typescript_exports),
444
+ ["x"]: x_exports,
445
+ ["x-legacy"]: toLegacyConfig(x_exports),
446
+ ["core"]: x_exports,
447
+ ["core-legacy"]: toLegacyConfig(x_exports),
448
+ ["off-dom"]: disable_dom_exports,
449
+ ["off-dom-legacy"]: toLegacyConfig(disable_dom_exports)
450
+ }
464
451
  };
465
452
 
466
- export { index_default as default };
453
+ //#endregion
454
+ export { src_default as default };