@santi020k/eslint-config-santi020k 2.0.1 → 3.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/README.md +18 -18
- package/dist/index.d.ts +16 -8
- package/dist/index.js +536 -422
- package/package.json +50 -47
- package/dist/configs/astro/index.config.d.ts +0 -9
- package/dist/configs/astro/rules.d.ts +0 -6
- package/dist/configs/expo/index.config.d.ts +0 -9
- package/dist/configs/expo/rules.d.ts +0 -6
- package/dist/configs/index.d.ts +0 -6
- package/dist/configs/js/index.config.d.ts +0 -3
- package/dist/configs/js/rules.d.ts +0 -4
- package/dist/configs/next/index.config.d.ts +0 -9
- package/dist/configs/next/rules.d.ts +0 -6
- package/dist/configs/react/index.config.d.ts +0 -11
- package/dist/configs/react/rules.d.ts +0 -3
- package/dist/configs/ts/index.config.d.ts +0 -3
- package/dist/configs/ts/rules.d.ts +0 -25
- package/dist/index.mjs +0 -466
- package/dist/optionals/cspell.d.ts +0 -15
- package/dist/optionals/i18next.d.ts +0 -2
- package/dist/optionals/index.d.ts +0 -5
- package/dist/optionals/mdx.d.ts +0 -21
- package/dist/optionals/tailwind.d.ts +0 -2
- package/dist/optionals/vitest.d.ts +0 -16
- package/dist/package.json +0 -104
- package/dist/utils/flatCompat.d.ts +0 -6
package/dist/index.js
CHANGED
|
@@ -1,466 +1,580 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
import configStandard from 'eslint-config-standard';
|
|
7
|
-
import pluginImport from 'eslint-plugin-import';
|
|
8
|
-
import pluginJsxA11y from 'eslint-plugin-jsx-a11y';
|
|
9
|
-
import pluginN from 'eslint-plugin-n';
|
|
10
|
-
import pluginPromise from 'eslint-plugin-promise';
|
|
11
|
-
import pluginSimpleImport from 'eslint-plugin-simple-import-sort';
|
|
12
|
-
import pluginSonarJs from 'eslint-plugin-sonarjs';
|
|
13
|
-
import pluginUnusedImport from 'eslint-plugin-unused-imports';
|
|
14
|
-
import globals from 'globals';
|
|
15
|
-
import pluginReactConfig from 'eslint-plugin-react/configs/recommended.js';
|
|
16
|
-
import pluginReactHooks from 'eslint-plugin-react-hooks';
|
|
17
|
-
import tsEslint from 'typescript-eslint';
|
|
18
|
-
import pluginCspell from '@cspell/eslint-plugin';
|
|
19
|
-
import pluginTailwind from 'eslint-plugin-tailwindcss';
|
|
20
|
-
import pluginVitest from 'eslint-plugin-vitest';
|
|
1
|
+
// src/utils/apply-config-if-option-present.ts
|
|
2
|
+
var applyConfigIfOptionPresent = (configs, option, configToAdd) => {
|
|
3
|
+
const isOptionIncluded = configs.includes(option);
|
|
4
|
+
return isOptionIncluded ? configToAdd : [];
|
|
5
|
+
};
|
|
21
6
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
purpose with or without fee is hereby granted.
|
|
27
|
-
|
|
28
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
29
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
30
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
31
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
32
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
33
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
34
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
35
|
-
***************************************************************************** */
|
|
36
|
-
/* global Reflect, Promise, SuppressedError, Symbol */
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
var __assign = function() {
|
|
40
|
-
__assign = Object.assign || function __assign(t) {
|
|
41
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
42
|
-
s = arguments[i];
|
|
43
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
44
|
-
}
|
|
45
|
-
return t;
|
|
46
|
-
};
|
|
47
|
-
return __assign.apply(this, arguments);
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
function __spreadArray(to, from, pack) {
|
|
51
|
-
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
52
|
-
if (ar || !(i in from)) {
|
|
53
|
-
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
54
|
-
ar[i] = from[i];
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
return to.concat(ar || Array.prototype.slice.call(from));
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
|
|
61
|
-
var e = new Error(message);
|
|
62
|
-
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
7
|
+
// src/utils/has-react-config.ts
|
|
8
|
+
var hasReactConfig = (configs) => {
|
|
9
|
+
if (!configs) return false;
|
|
10
|
+
return ReactConfigs.some((reactConfig2) => configs.includes(reactConfig2));
|
|
63
11
|
};
|
|
64
12
|
|
|
65
|
-
//
|
|
66
|
-
|
|
67
|
-
baseDirectory: getDirname(),
|
|
68
|
-
recommendedConfig: {}
|
|
69
|
-
});
|
|
13
|
+
// src/configs/astro/index.config.ts
|
|
14
|
+
import pluginAstro from "eslint-plugin-astro";
|
|
70
15
|
|
|
16
|
+
// src/configs/js/rules.ts
|
|
71
17
|
var groups = [
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
18
|
+
// Internal packages.
|
|
19
|
+
// Atomic Design and components
|
|
20
|
+
["^(components|@/components|@components)(/.*|$)"],
|
|
21
|
+
["^(ui|@/ui|@ui)(/.*|$)"],
|
|
22
|
+
["^(atoms|@/atoms|@atoms)(/.*|$)"],
|
|
23
|
+
["^(molecules|@/molecules|@molecules)(/.*|$)"],
|
|
24
|
+
["^(organisms|@/organisms|@organisms)(/.*|$)"],
|
|
25
|
+
["^(templates|@/templates|@templates)(/.*|$)"],
|
|
26
|
+
["^(pages|@/pages|@pages)(/.*|$)"],
|
|
27
|
+
// Other posible folders
|
|
28
|
+
["^(store|@/store|@store)(/.*|$)"],
|
|
29
|
+
["^(api|@/api|@api)(/.*|$)"],
|
|
30
|
+
["^(contexts|@/contexts|@contexts)(/.*|$)"],
|
|
31
|
+
["^(hooks|@/hooks|@hooks)(/.*|$)"],
|
|
32
|
+
["^(lib|@/lib|@lib)(/.*|$)"],
|
|
33
|
+
["^(services|@/services|@services)(/.*|$)"],
|
|
34
|
+
["^(models|@/models|@models)(/.*|$)"],
|
|
35
|
+
["^(utils|@/utils|@utils)(/.*|$)"],
|
|
36
|
+
["^(ws|@/ws|@ws)(/.*|$)"],
|
|
37
|
+
// npm packages
|
|
38
|
+
// Anything that starts with a letter (or digit or underscore), or `@` followed by a letter.
|
|
39
|
+
["^\\w"],
|
|
40
|
+
// Side effect imports.
|
|
41
|
+
["^\\u0000"],
|
|
42
|
+
// Other relative imports. Put same-folder imports and `.` last.
|
|
43
|
+
["^\\./(?=.*/)(?!/?$)", "^\\.(?!/?$)", "^\\./?$"],
|
|
44
|
+
// Parent imports. Put `..` last.
|
|
45
|
+
["^\\.\\.(?!/?$)", "^\\.\\./?$"],
|
|
46
|
+
// Style imports.
|
|
47
|
+
["^.+\\.?(css|scss)$"]
|
|
102
48
|
];
|
|
103
|
-
var rules
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
}
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
}],
|
|
144
|
-
'@stylistic/no-extra-parens': 'off',
|
|
145
|
-
'@stylistic/max-len': [
|
|
146
|
-
'warn',
|
|
147
|
-
{
|
|
148
|
-
code: 120,
|
|
149
|
-
tabWidth: 2,
|
|
150
|
-
comments: 200,
|
|
151
|
-
ignoreStrings: true
|
|
152
|
-
}
|
|
153
|
-
],
|
|
154
|
-
'@stylistic/max-statements-per-line': ['warn', { max: 1 }],
|
|
155
|
-
'@stylistic/array-element-newline': ['warn', 'consistent'],
|
|
156
|
-
'@stylistic/no-extra-semi': 'off',
|
|
157
|
-
'@stylistic/no-multi-spaces': 'off',
|
|
158
|
-
'@stylistic/padding-line-between-statements': [
|
|
159
|
-
'warn',
|
|
160
|
-
{ blankLine: 'always', prev: '*', next: '*' },
|
|
161
|
-
{ blankLine: 'any', prev: 'import', next: 'import' },
|
|
162
|
-
{
|
|
163
|
-
blankLine: 'always',
|
|
164
|
-
prev: ['const', 'let', 'var'],
|
|
165
|
-
next: ['const', 'let', 'var']
|
|
166
|
-
},
|
|
167
|
-
{
|
|
168
|
-
blankLine: 'never',
|
|
169
|
-
prev: ['singleline-const', 'singleline-let', 'singleline-var'],
|
|
170
|
-
next: ['singleline-const', 'singleline-let', 'singleline-var']
|
|
171
|
-
},
|
|
172
|
-
{ blankLine: 'always', prev: 'block-like', next: 'const' },
|
|
173
|
-
{ blankLine: 'always', prev: 'const', next: 'block-like' }
|
|
174
|
-
],
|
|
175
|
-
'@stylistic/function-paren-newline': ['warn', 'consistent'],
|
|
176
|
-
'arrow-body-style': ['warn', 'as-needed'],
|
|
177
|
-
'prefer-arrow-callback': ['warn', { allowNamedFunctions: true }],
|
|
178
|
-
'func-style': ['warn', 'expression', { allowArrowFunctions: true }],
|
|
179
|
-
'simple-import-sort/imports': [
|
|
180
|
-
'warn',
|
|
181
|
-
{
|
|
182
|
-
groups: groups
|
|
183
|
-
}
|
|
184
|
-
],
|
|
185
|
-
'jsx-a11y/alt-text': 'warn',
|
|
186
|
-
'no-empty': 'warn',
|
|
187
|
-
'no-nested-ternary': 'warn',
|
|
188
|
-
'no-undef': 'warn',
|
|
189
|
-
'unused-imports/no-unused-vars': [
|
|
190
|
-
'warn',
|
|
191
|
-
{
|
|
192
|
-
vars: 'all',
|
|
193
|
-
varsIgnorePattern: '^_',
|
|
194
|
-
args: 'after-used',
|
|
195
|
-
argsIgnorePattern: '^_',
|
|
196
|
-
destructuredArrayIgnorePattern: '^_',
|
|
197
|
-
ignoreRestSiblings: true
|
|
198
|
-
}
|
|
199
|
-
],
|
|
200
|
-
'no-void': 'warn',
|
|
201
|
-
camelcase: 'warn',
|
|
202
|
-
'array-callback-return': 'warn',
|
|
203
|
-
'no-fallthrough': 'warn',
|
|
204
|
-
eqeqeq: 'warn',
|
|
205
|
-
'no-constant-binary-expression': 'warn',
|
|
206
|
-
'@stylistic/lines-around-comment': 'warn',
|
|
207
|
-
'import/no-duplicates': 'warn',
|
|
208
|
-
'valid-typeof': 'warn',
|
|
209
|
-
'no-constant-condition': 'warn',
|
|
210
|
-
'no-use-before-define': 'warn',
|
|
211
|
-
'@stylistic/implicit-arrow-linebreak': 'warn',
|
|
212
|
-
'import/export': 'warn',
|
|
213
|
-
'no-useless-escape': 'warn',
|
|
214
|
-
'no-useless-return': 'warn',
|
|
215
|
-
'prefer-promise-reject-errors': 'warn',
|
|
216
|
-
'no-useless-constructor': 'warn',
|
|
217
|
-
'no-new': 'warn',
|
|
218
|
-
'prefer-regex-literals': 'warn',
|
|
219
|
-
'@stylistic/multiline-comment-style': 'off',
|
|
220
|
-
'space-before-function-paren': 'off'
|
|
221
|
-
};
|
|
222
|
-
|
|
223
|
-
var rules$4 = {
|
|
224
|
-
'simple-import-sort/imports': [
|
|
225
|
-
'warn',
|
|
226
|
-
{
|
|
227
|
-
groups: __spreadArray([
|
|
228
|
-
// Packages `react` related packages come first.
|
|
229
|
-
['^react'],
|
|
230
|
-
['^(astro)(/.*|$)?']
|
|
231
|
-
], groups, true)
|
|
49
|
+
var rules = {
|
|
50
|
+
"unused-imports/no-unused-imports": "warn",
|
|
51
|
+
indent: "off",
|
|
52
|
+
"brace-style": "off",
|
|
53
|
+
"@stylistic/brace-style": ["warn", "1tbs"],
|
|
54
|
+
"@stylistic/indent": ["warn", 2],
|
|
55
|
+
"@stylistic/quote-props": ["warn", "as-needed"],
|
|
56
|
+
quotes: "off",
|
|
57
|
+
"@stylistic/quotes": ["warn", "single"],
|
|
58
|
+
"@stylistic/semi": ["warn", "never"],
|
|
59
|
+
"quote-props": "off",
|
|
60
|
+
"comma-dangle": "off",
|
|
61
|
+
"@stylistic/comma-dangle": ["warn", "never"],
|
|
62
|
+
"@stylistic/object-curly-spacing": ["warn", "always"],
|
|
63
|
+
"@stylistic/padded-blocks": ["warn", "never"],
|
|
64
|
+
"@stylistic/arrow-parens": ["warn", "as-needed"],
|
|
65
|
+
"@stylistic/dot-location": ["warn", "property"],
|
|
66
|
+
"@stylistic/function-call-argument-newline": ["warn", "never"],
|
|
67
|
+
"@stylistic/object-property-newline": [
|
|
68
|
+
"warn",
|
|
69
|
+
{ allowAllPropertiesOnSameLine: true }
|
|
70
|
+
],
|
|
71
|
+
"@stylistic/multiline-ternary": ["warn", "always-multiline"],
|
|
72
|
+
"@stylistic/member-delimiter-style": ["error", {
|
|
73
|
+
multiline: {
|
|
74
|
+
delimiter: "none",
|
|
75
|
+
requireLast: false
|
|
76
|
+
},
|
|
77
|
+
singleline: {
|
|
78
|
+
delimiter: "comma",
|
|
79
|
+
requireLast: false
|
|
80
|
+
},
|
|
81
|
+
overrides: {
|
|
82
|
+
interface: {
|
|
83
|
+
multiline: {
|
|
84
|
+
delimiter: "none",
|
|
85
|
+
requireLast: false
|
|
232
86
|
}
|
|
233
|
-
|
|
234
|
-
}
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
parser: 'astro-eslint-parser'
|
|
240
|
-
},
|
|
241
|
-
{
|
|
242
|
-
files: ['*.md', '*.mdx'],
|
|
243
|
-
extends: ['plugin:mdx/recommended'],
|
|
244
|
-
settings: {
|
|
245
|
-
'mdx/code-blocks': true,
|
|
246
|
-
'mdx/language-mapper': {}
|
|
247
|
-
},
|
|
248
|
-
rules: {
|
|
249
|
-
'max-len': 'off',
|
|
250
|
-
'react/react-in-jsx-scope': 'off'
|
|
251
|
-
}
|
|
252
|
-
}]
|
|
253
|
-
})), true), [
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
}],
|
|
90
|
+
"@stylistic/no-extra-parens": "off",
|
|
91
|
+
"@stylistic/max-len": [
|
|
92
|
+
"warn",
|
|
254
93
|
{
|
|
255
|
-
|
|
256
|
-
|
|
94
|
+
code: 120,
|
|
95
|
+
tabWidth: 2,
|
|
96
|
+
comments: 200,
|
|
97
|
+
ignoreStrings: true
|
|
257
98
|
}
|
|
258
|
-
],
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
99
|
+
],
|
|
100
|
+
"@stylistic/max-statements-per-line": ["warn", { max: 1 }],
|
|
101
|
+
"@stylistic/array-element-newline": ["warn", "consistent"],
|
|
102
|
+
"@stylistic/no-extra-semi": "off",
|
|
103
|
+
"@stylistic/no-multi-spaces": "off",
|
|
104
|
+
"@stylistic/padding-line-between-statements": [
|
|
105
|
+
"warn",
|
|
106
|
+
{ blankLine: "always", prev: "*", next: "*" },
|
|
107
|
+
{ blankLine: "any", prev: "import", next: "import" },
|
|
267
108
|
{
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
promise: pluginPromise,
|
|
272
|
-
import: { rules: pluginImport.rules },
|
|
273
|
-
'simple-import-sort': pluginSimpleImport,
|
|
274
|
-
'jsx-a11y': pluginJsxA11y,
|
|
275
|
-
'unused-imports': pluginUnusedImport,
|
|
276
|
-
sonarjs: pluginSonarJs
|
|
277
|
-
},
|
|
278
|
-
languageOptions: languageOptions$1,
|
|
279
|
-
rules: __assign(__assign(__assign({}, configStandard.rules), pluginSonarJs.configs.recommended.rules), { 'import/first': 'off' })
|
|
109
|
+
blankLine: "always",
|
|
110
|
+
prev: ["const", "let", "var"],
|
|
111
|
+
next: ["const", "let", "var"]
|
|
280
112
|
},
|
|
281
|
-
__assign({ name: 'stylistic' }, pluginStylistic.configs['recommended-flat']),
|
|
282
113
|
{
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
ignores: ['node_modules/*'],
|
|
287
|
-
rules: rules$5
|
|
114
|
+
blankLine: "never",
|
|
115
|
+
prev: ["singleline-const", "singleline-let", "singleline-var"],
|
|
116
|
+
next: ["singleline-const", "singleline-let", "singleline-var"]
|
|
288
117
|
},
|
|
118
|
+
{ blankLine: "always", prev: "block-like", next: "const" },
|
|
119
|
+
{ blankLine: "always", prev: "const", next: "block-like" }
|
|
120
|
+
],
|
|
121
|
+
"@stylistic/function-paren-newline": ["warn", "consistent"],
|
|
122
|
+
"arrow-body-style": ["warn", "as-needed"],
|
|
123
|
+
"prefer-arrow-callback": ["warn", { allowNamedFunctions: true }],
|
|
124
|
+
"func-style": ["warn", "expression", { allowArrowFunctions: true }],
|
|
125
|
+
"simple-import-sort/imports": [
|
|
126
|
+
"warn",
|
|
289
127
|
{
|
|
290
|
-
|
|
291
|
-
ignores: ['node_modules/*']
|
|
128
|
+
groups
|
|
292
129
|
}
|
|
293
|
-
]
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
130
|
+
],
|
|
131
|
+
"jsx-a11y/alt-text": "warn",
|
|
132
|
+
"no-empty": "warn",
|
|
133
|
+
"no-nested-ternary": "warn",
|
|
134
|
+
"no-undef": "warn",
|
|
135
|
+
"unused-imports/no-unused-vars": [
|
|
136
|
+
"warn",
|
|
137
|
+
{
|
|
138
|
+
vars: "all",
|
|
139
|
+
varsIgnorePattern: "^_",
|
|
140
|
+
args: "after-used",
|
|
141
|
+
argsIgnorePattern: "^_",
|
|
142
|
+
destructuredArrayIgnorePattern: "^_",
|
|
143
|
+
ignoreRestSiblings: true
|
|
144
|
+
}
|
|
145
|
+
],
|
|
146
|
+
"no-void": "warn",
|
|
147
|
+
camelcase: "warn",
|
|
148
|
+
"array-callback-return": "warn",
|
|
149
|
+
"no-fallthrough": "warn",
|
|
150
|
+
eqeqeq: "warn",
|
|
151
|
+
"no-constant-binary-expression": "warn",
|
|
152
|
+
"@stylistic/lines-around-comment": "warn",
|
|
153
|
+
"import/no-duplicates": "warn",
|
|
154
|
+
"valid-typeof": "warn",
|
|
155
|
+
"no-constant-condition": "warn",
|
|
156
|
+
"no-use-before-define": "warn",
|
|
157
|
+
"@stylistic/implicit-arrow-linebreak": "warn",
|
|
158
|
+
"import/export": "warn",
|
|
159
|
+
"no-useless-escape": "warn",
|
|
160
|
+
"no-useless-return": "warn",
|
|
161
|
+
"prefer-promise-reject-errors": "warn",
|
|
162
|
+
"no-useless-constructor": "warn",
|
|
163
|
+
"no-new": "warn",
|
|
164
|
+
"prefer-regex-literals": "warn",
|
|
165
|
+
"@stylistic/multiline-comment-style": "off",
|
|
166
|
+
"space-before-function-paren": "off"
|
|
306
167
|
};
|
|
307
168
|
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
},
|
|
169
|
+
// src/configs/astro/rules.ts
|
|
170
|
+
var rules2 = {
|
|
171
|
+
"simple-import-sort/imports": [
|
|
172
|
+
"warn",
|
|
313
173
|
{
|
|
314
|
-
|
|
315
|
-
|
|
174
|
+
groups: [
|
|
175
|
+
// Packages `react` related packages come first.
|
|
176
|
+
["^react"],
|
|
177
|
+
["^(astro)(/.*|$)?"],
|
|
178
|
+
...groups
|
|
179
|
+
]
|
|
316
180
|
}
|
|
317
|
-
],
|
|
181
|
+
],
|
|
182
|
+
// Disable no-unresolved rule for .astro files
|
|
183
|
+
"react/jsx-filename-extension": [1, { extensions: [".astro"] }],
|
|
184
|
+
// Accept jsx in astro files
|
|
185
|
+
"react/destructuring-assignment": "off",
|
|
186
|
+
// Vscode doesn't support automatically destructuring, it's a pain to add a new variable
|
|
187
|
+
"react/require-default-props": "off",
|
|
188
|
+
// Allow non-defined react props as undefined
|
|
189
|
+
"react/jsx-props-no-spreading": "off",
|
|
190
|
+
// _app.tsx uses spread operator and also, react-hook-form
|
|
191
|
+
"react/react-in-jsx-scope": "off",
|
|
192
|
+
"react/no-unknown-property": "off",
|
|
193
|
+
// Disable conflicted rules
|
|
194
|
+
"@stylistic/jsx-indent": "off",
|
|
195
|
+
"@stylistic/jsx-one-expression-per-line": "off",
|
|
196
|
+
"@stylistic/jsx-tag-spacing": "off",
|
|
197
|
+
"react/jsx-key": "off"
|
|
198
|
+
};
|
|
318
199
|
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
'react/no-deprecated': 'warn',
|
|
348
|
-
'react/no-multi-comp': 'warn',
|
|
349
|
-
'react/no-unescaped-entities': 'warn',
|
|
350
|
-
'react/jsx-no-undef': 'warn',
|
|
351
|
-
'react/no-unknown-property': 'warn',
|
|
352
|
-
'simple-import-sort/imports': [
|
|
353
|
-
'warn',
|
|
354
|
-
{
|
|
355
|
-
groups: __spreadArray([
|
|
356
|
-
// Packages `react` related packages come first.
|
|
357
|
-
['^react']
|
|
358
|
-
], groups, true)
|
|
359
|
-
}
|
|
360
|
-
]
|
|
200
|
+
// src/configs/astro/index.config.ts
|
|
201
|
+
var astroConfig = [
|
|
202
|
+
...pluginAstro.configs.recommended,
|
|
203
|
+
{
|
|
204
|
+
files: ["**/*.astro"],
|
|
205
|
+
name: "custom-astro",
|
|
206
|
+
rules: rules2
|
|
207
|
+
}
|
|
208
|
+
];
|
|
209
|
+
|
|
210
|
+
// src/configs/js/index.config.ts
|
|
211
|
+
import configStandard from "eslint-config-standard";
|
|
212
|
+
import pluginImport from "eslint-plugin-import";
|
|
213
|
+
import pluginJsxA11y from "eslint-plugin-jsx-a11y";
|
|
214
|
+
import pluginN from "eslint-plugin-n";
|
|
215
|
+
import pluginPromise from "eslint-plugin-promise";
|
|
216
|
+
import pluginSimpleImport from "eslint-plugin-simple-import-sort";
|
|
217
|
+
import pluginUnusedImport from "eslint-plugin-unused-imports";
|
|
218
|
+
import globals from "globals";
|
|
219
|
+
import eslint from "@eslint/js";
|
|
220
|
+
import pluginStylistic from "@stylistic/eslint-plugin";
|
|
221
|
+
var languageOptions = {
|
|
222
|
+
ecmaVersion: "latest",
|
|
223
|
+
sourceType: "module",
|
|
224
|
+
globals: {
|
|
225
|
+
...globals.browser,
|
|
226
|
+
...globals.node
|
|
227
|
+
}
|
|
361
228
|
};
|
|
229
|
+
var jsConfig = [
|
|
230
|
+
{
|
|
231
|
+
name: "eslint-config",
|
|
232
|
+
...eslint.configs.recommended
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
name: "plugins",
|
|
236
|
+
plugins: {
|
|
237
|
+
n: pluginN,
|
|
238
|
+
promise: pluginPromise,
|
|
239
|
+
import: { rules: pluginImport.rules },
|
|
240
|
+
"simple-import-sort": pluginSimpleImport,
|
|
241
|
+
"jsx-a11y": pluginJsxA11y,
|
|
242
|
+
"unused-imports": pluginUnusedImport
|
|
243
|
+
// sonarjs: pluginSonarJs
|
|
244
|
+
},
|
|
245
|
+
languageOptions,
|
|
246
|
+
rules: {
|
|
247
|
+
...configStandard.rules,
|
|
248
|
+
// ...pluginSonarJs.configs.recommended.rules,
|
|
249
|
+
"import/first": "off"
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
{
|
|
253
|
+
name: "stylistic",
|
|
254
|
+
...pluginStylistic.configs["recommended-flat"]
|
|
255
|
+
},
|
|
256
|
+
{
|
|
257
|
+
name: "custom-js",
|
|
258
|
+
languageOptions,
|
|
259
|
+
files: ["**/*.{js,jsx,mjs,cjs}"],
|
|
260
|
+
ignores: ["node_modules/*"],
|
|
261
|
+
rules
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
name: "ignore-node-modules-js",
|
|
265
|
+
ignores: ["node_modules/*"]
|
|
266
|
+
}
|
|
267
|
+
];
|
|
362
268
|
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
269
|
+
// src/utils/flat-compat.ts
|
|
270
|
+
import { getDirname } from "cross-dirname";
|
|
271
|
+
import { FlatCompat } from "@eslint/eslintrc";
|
|
272
|
+
var flatCompat = new FlatCompat({
|
|
273
|
+
baseDirectory: getDirname(),
|
|
274
|
+
recommendedConfig: {}
|
|
275
|
+
});
|
|
276
|
+
|
|
277
|
+
// src/configs/next/rules.ts
|
|
278
|
+
var rules3 = {
|
|
279
|
+
"simple-import-sort/imports": [
|
|
280
|
+
"warn",
|
|
369
281
|
{
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
rules: __assign(__assign({}, pluginReactHooks.configs.recommended.rules), rules$2)
|
|
282
|
+
groups: [
|
|
283
|
+
// Packages `react` related packages come first.
|
|
284
|
+
["^react"],
|
|
285
|
+
["^(next)(/.*|$)?"],
|
|
286
|
+
...groups
|
|
287
|
+
]
|
|
377
288
|
}
|
|
378
|
-
]
|
|
289
|
+
]
|
|
290
|
+
};
|
|
379
291
|
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
292
|
+
// src/configs/next/index.config.ts
|
|
293
|
+
import { fixupConfigRules } from "@eslint/compat";
|
|
294
|
+
var nextConfig = [
|
|
295
|
+
...fixupConfigRules(flatCompat.extends("plugin:@next/next/core-web-vitals")),
|
|
296
|
+
{
|
|
297
|
+
name: "custom-next",
|
|
298
|
+
rules: rules3
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
name: "ignore-next-folder",
|
|
302
|
+
ignores: [".next/*"]
|
|
303
|
+
}
|
|
304
|
+
];
|
|
391
305
|
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
306
|
+
// src/configs/react/index.config.ts
|
|
307
|
+
import pluginReactConfig from "eslint-plugin-react/configs/recommended.js";
|
|
308
|
+
import pluginReactHooks from "eslint-plugin-react-hooks";
|
|
309
|
+
import globals2 from "globals";
|
|
310
|
+
|
|
311
|
+
// src/configs/react/rules.ts
|
|
312
|
+
var rules4 = {
|
|
313
|
+
"react/react-in-jsx-scope": "off",
|
|
314
|
+
"react/jsx-max-depth": ["warn", { max: 7 }],
|
|
315
|
+
"react/prop-types": "off",
|
|
316
|
+
"react-hooks/exhaustive-deps": "off",
|
|
317
|
+
"react/button-has-type": "warn",
|
|
318
|
+
"react/display-name": "warn",
|
|
319
|
+
"react/no-children-prop": "warn",
|
|
320
|
+
"react/no-danger-with-children": "warn",
|
|
321
|
+
"react/no-unstable-nested-components": "warn",
|
|
322
|
+
"react/self-closing-comp": ["warn", { component: true, html: true }],
|
|
323
|
+
"react/jsx-curly-brace-presence": [
|
|
324
|
+
"warn",
|
|
325
|
+
{ props: "never", children: "never" }
|
|
326
|
+
],
|
|
327
|
+
"react/jsx-curly-newline": "warn",
|
|
328
|
+
"react/destructuring-assignment": "warn",
|
|
329
|
+
"react/jsx-pascal-case": "warn",
|
|
330
|
+
"react/boolean-prop-naming": "warn",
|
|
331
|
+
"react/hook-use-state": "warn",
|
|
332
|
+
"react/jsx-boolean-value": "warn",
|
|
333
|
+
"react/jsx-closing-tag-location": "warn",
|
|
334
|
+
"react/jsx-closing-bracket-location": "warn",
|
|
335
|
+
"react/jsx-wrap-multilines": "warn",
|
|
336
|
+
"react/jsx-no-target-blank": "warn",
|
|
337
|
+
"react/jsx-no-leaked-render": "warn",
|
|
338
|
+
"react/jsx-handler-names": "warn",
|
|
339
|
+
"react/jsx-fragments": "warn",
|
|
340
|
+
"react/no-deprecated": "warn",
|
|
341
|
+
"react/no-multi-comp": "warn",
|
|
342
|
+
"react/no-unescaped-entities": "warn",
|
|
343
|
+
"react/jsx-no-undef": "warn",
|
|
344
|
+
"react/no-unknown-property": "warn",
|
|
345
|
+
"simple-import-sort/imports": [
|
|
346
|
+
"warn",
|
|
398
347
|
{
|
|
399
|
-
|
|
400
|
-
|
|
348
|
+
groups: [
|
|
349
|
+
// Packages `react` related packages come first.
|
|
350
|
+
["^react"],
|
|
351
|
+
...groups
|
|
352
|
+
]
|
|
401
353
|
}
|
|
402
|
-
]
|
|
354
|
+
]
|
|
355
|
+
};
|
|
403
356
|
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
]
|
|
357
|
+
// src/configs/react/index.config.ts
|
|
358
|
+
import { fixupConfigRules as fixupConfigRules2 } from "@eslint/compat";
|
|
359
|
+
var languageOptions2 = {
|
|
360
|
+
ecmaVersion: "latest",
|
|
361
|
+
sourceType: "module",
|
|
362
|
+
...pluginReactConfig.languageOptions,
|
|
363
|
+
globals: {
|
|
364
|
+
...globals2.browser,
|
|
365
|
+
...globals2.node
|
|
366
|
+
}
|
|
415
367
|
};
|
|
368
|
+
var reactConfig = [
|
|
369
|
+
...fixupConfigRules2(pluginReactConfig).map((react) => ({
|
|
370
|
+
...react,
|
|
371
|
+
name: "react",
|
|
372
|
+
languageOptions: languageOptions2,
|
|
373
|
+
settings: {
|
|
374
|
+
react: {
|
|
375
|
+
version: "detect"
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
})),
|
|
379
|
+
{
|
|
380
|
+
name: "custom-react",
|
|
381
|
+
plugins: {
|
|
382
|
+
"react-hooks": pluginReactHooks
|
|
383
|
+
},
|
|
384
|
+
languageOptions: languageOptions2,
|
|
385
|
+
files: ["**/*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}"],
|
|
386
|
+
rules: {
|
|
387
|
+
...pluginReactHooks.configs.recommended.rules,
|
|
388
|
+
...rules4
|
|
389
|
+
}
|
|
390
|
+
}
|
|
391
|
+
];
|
|
416
392
|
|
|
417
|
-
|
|
393
|
+
// src/configs/ts/index.config.ts
|
|
394
|
+
import tsEslint from "typescript-eslint";
|
|
395
|
+
|
|
396
|
+
// src/configs/ts/rules.ts
|
|
397
|
+
var rules5 = {
|
|
398
|
+
// ! js rules are not enabled in ts files, eslint rules would be duplicated, this can be improved in the future
|
|
399
|
+
...rules,
|
|
400
|
+
semi: "off",
|
|
401
|
+
"no-unused-vars": "off",
|
|
402
|
+
"@typescript-eslint/indent": "off",
|
|
403
|
+
"@typescript-eslint/no-unused-vars": [
|
|
404
|
+
"warn",
|
|
418
405
|
{
|
|
419
|
-
|
|
420
|
-
|
|
406
|
+
vars: "all",
|
|
407
|
+
varsIgnorePattern: "^_",
|
|
408
|
+
args: "after-used",
|
|
409
|
+
argsIgnorePattern: "^_",
|
|
410
|
+
destructuredArrayIgnorePattern: "^_",
|
|
411
|
+
ignoreRestSiblings: true
|
|
421
412
|
}
|
|
422
|
-
],
|
|
413
|
+
],
|
|
414
|
+
"@typescript-eslint/no-explicit-any": "warn",
|
|
415
|
+
"@typescript-eslint/no-empty-function": "warn",
|
|
416
|
+
"@typescript-eslint/no-empty-object-type": "warn",
|
|
417
|
+
"@typescript-eslint/no-unsafe-function-type": "warn",
|
|
418
|
+
"@typescript-eslint/no-wrapper-object-types": "warn",
|
|
419
|
+
"@typescript-eslint/no-var-requires": "warn",
|
|
420
|
+
"@typescript-eslint/ban-ts-comment": "warn",
|
|
421
|
+
"@typescript-eslint/no-non-null-assertion": "warn",
|
|
422
|
+
"@typescript-eslint/no-invalid-void-type": "warn",
|
|
423
|
+
"@typescript-eslint/no-dynamic-delete": "warn",
|
|
424
|
+
"@typescript-eslint/no-useless-constructor": "warn",
|
|
425
|
+
"@typescript-eslint/prefer-for-of": "warn",
|
|
426
|
+
"@typescript-eslint/no-duplicate-enum-values": "warn"
|
|
427
|
+
};
|
|
423
428
|
|
|
424
|
-
|
|
429
|
+
// src/configs/ts/index.config.ts
|
|
430
|
+
import tsParser from "@typescript-eslint/parser";
|
|
431
|
+
var tsConfig = [
|
|
432
|
+
...tsEslint.configs.stylistic,
|
|
433
|
+
{
|
|
434
|
+
name: "custom-ts",
|
|
435
|
+
files: ["**/*.{ts,tsx,mts,cts}"],
|
|
436
|
+
rules: rules5,
|
|
437
|
+
languageOptions: {
|
|
438
|
+
parserOptions: {
|
|
439
|
+
parser: tsParser
|
|
440
|
+
},
|
|
441
|
+
ecmaVersion: "latest"
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
// TODO: Temporal
|
|
445
|
+
// {
|
|
446
|
+
// name: 'ignore-node-modules-ts',
|
|
447
|
+
// ignores: ['node_modules/*']
|
|
448
|
+
// }
|
|
449
|
+
];
|
|
450
|
+
|
|
451
|
+
// src/configs/expo/rules.ts
|
|
452
|
+
var rules6 = {
|
|
453
|
+
"simple-import-sort/imports": [
|
|
454
|
+
"warn",
|
|
425
455
|
{
|
|
426
|
-
|
|
427
|
-
|
|
456
|
+
groups: [
|
|
457
|
+
// Packages `react` related packages come first.
|
|
458
|
+
["^react"],
|
|
459
|
+
["^(expo)(/.*|$)?"],
|
|
460
|
+
...groups
|
|
461
|
+
]
|
|
428
462
|
}
|
|
463
|
+
]
|
|
464
|
+
};
|
|
465
|
+
|
|
466
|
+
// src/configs/expo/index.config.ts
|
|
467
|
+
import { fixupConfigRules as fixupConfigRules3 } from "@eslint/compat";
|
|
468
|
+
var expoConfig = [
|
|
469
|
+
...fixupConfigRules3(flatCompat.extends("expo")),
|
|
470
|
+
{
|
|
471
|
+
name: "custom-expo",
|
|
472
|
+
rules: rules6
|
|
473
|
+
}
|
|
474
|
+
];
|
|
475
|
+
|
|
476
|
+
// src/optionals/cspell.ts
|
|
477
|
+
import pluginCspell from "@cspell/eslint-plugin";
|
|
478
|
+
var cspell = [
|
|
479
|
+
{
|
|
480
|
+
name: "cspell",
|
|
481
|
+
plugins: { "@cspell": pluginCspell }
|
|
482
|
+
}
|
|
483
|
+
];
|
|
484
|
+
|
|
485
|
+
// src/optionals/i18next.ts
|
|
486
|
+
import { fixupConfigRules as fixupConfigRules4 } from "@eslint/compat";
|
|
487
|
+
var i18next = [
|
|
488
|
+
...fixupConfigRules4(flatCompat.plugins("i18next"))
|
|
429
489
|
];
|
|
430
490
|
|
|
431
|
-
|
|
491
|
+
// src/optionals/mdx.ts
|
|
492
|
+
import pluginMdx from "eslint-plugin-mdx";
|
|
493
|
+
var mdx = [
|
|
494
|
+
{
|
|
495
|
+
...pluginMdx.flat
|
|
496
|
+
},
|
|
497
|
+
{
|
|
498
|
+
...pluginMdx.flatCodeBlocks,
|
|
499
|
+
rules: {
|
|
500
|
+
...pluginMdx.flatCodeBlocks.rules
|
|
501
|
+
}
|
|
502
|
+
}
|
|
503
|
+
];
|
|
432
504
|
|
|
433
|
-
|
|
505
|
+
// src/optionals/tailwind.ts
|
|
506
|
+
import pluginTailwind from "eslint-plugin-tailwindcss";
|
|
507
|
+
var tailwind = [...pluginTailwind.configs["flat/recommended"]];
|
|
434
508
|
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
509
|
+
// src/optionals/vitest.ts
|
|
510
|
+
import pluginVitest from "eslint-plugin-vitest";
|
|
511
|
+
import { fixupConfigRules as fixupConfigRules5 } from "@eslint/compat";
|
|
512
|
+
var vitest = [
|
|
513
|
+
...fixupConfigRules5(flatCompat.extends("plugin:testing-library/react")),
|
|
514
|
+
{
|
|
515
|
+
name: "vitest",
|
|
516
|
+
files: ["tests/**"],
|
|
517
|
+
// or any other pattern
|
|
518
|
+
plugins: {
|
|
519
|
+
vitest: pluginVitest
|
|
520
|
+
},
|
|
521
|
+
rules: {
|
|
522
|
+
...pluginVitest.configs.recommended.rules,
|
|
523
|
+
// you can also use vitest.configs.all.rules to enable all rules
|
|
524
|
+
"vitest/max-nested-describe": ["error", { max: 3 }],
|
|
525
|
+
// you can also modify rules' behavior using option like this
|
|
526
|
+
"vitest/expect-expect": [
|
|
527
|
+
"error",
|
|
528
|
+
{
|
|
529
|
+
assertFunctionNames: ["expect", "assert", "should"]
|
|
530
|
+
}
|
|
531
|
+
]
|
|
532
|
+
}
|
|
533
|
+
}
|
|
534
|
+
];
|
|
438
535
|
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
536
|
+
// src/index.ts
|
|
537
|
+
var ConfigOption2 = /* @__PURE__ */ ((ConfigOption3) => {
|
|
538
|
+
ConfigOption3["Ts"] = "ts";
|
|
539
|
+
ConfigOption3["React"] = "react";
|
|
540
|
+
ConfigOption3["Next"] = "next";
|
|
541
|
+
ConfigOption3["Expo"] = "expo";
|
|
542
|
+
ConfigOption3["Astro"] = "astro";
|
|
543
|
+
return ConfigOption3;
|
|
544
|
+
})(ConfigOption2 || {});
|
|
545
|
+
var OptionalOption = /* @__PURE__ */ ((OptionalOption2) => {
|
|
546
|
+
OptionalOption2["Cspell"] = "cspell";
|
|
547
|
+
OptionalOption2["Tailwind"] = "tailwind";
|
|
548
|
+
OptionalOption2["Vitest"] = "vitest";
|
|
549
|
+
OptionalOption2["I18next"] = "i18next";
|
|
550
|
+
OptionalOption2["Mdx"] = "mdx";
|
|
551
|
+
return OptionalOption2;
|
|
552
|
+
})(OptionalOption || {});
|
|
454
553
|
var ReactConfigs = [
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
554
|
+
"react" /* React */,
|
|
555
|
+
"astro" /* Astro */,
|
|
556
|
+
"next" /* Next */,
|
|
557
|
+
"expo" /* Expo */
|
|
458
558
|
];
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
559
|
+
var eslintConfig = ({ config = [], optionals = [] } = {}) => {
|
|
560
|
+
const hasReact = hasReactConfig(config);
|
|
561
|
+
return [
|
|
562
|
+
...jsConfig,
|
|
563
|
+
...hasReact ? reactConfig : [],
|
|
564
|
+
...applyConfigIfOptionPresent(config, "ts" /* Ts */, tsConfig),
|
|
565
|
+
...applyConfigIfOptionPresent(config, "next" /* Next */, nextConfig),
|
|
566
|
+
...applyConfigIfOptionPresent(config, "astro" /* Astro */, astroConfig),
|
|
567
|
+
...applyConfigIfOptionPresent(config, "expo" /* Expo */, expoConfig),
|
|
568
|
+
...optionals.includes("cspell" /* Cspell */) ? cspell : [],
|
|
569
|
+
...optionals.includes("tailwind" /* Tailwind */) ? tailwind : [],
|
|
570
|
+
...optionals.includes("vitest" /* Vitest */) ? vitest : [],
|
|
571
|
+
...optionals.includes("i18next" /* I18next */) ? i18next : [],
|
|
572
|
+
...optionals.includes("mdx" /* Mdx */) ? mdx : []
|
|
573
|
+
];
|
|
574
|
+
};
|
|
575
|
+
export {
|
|
576
|
+
ConfigOption2 as ConfigOption,
|
|
577
|
+
OptionalOption,
|
|
578
|
+
ReactConfigs,
|
|
579
|
+
eslintConfig
|
|
464
580
|
};
|
|
465
|
-
|
|
466
|
-
export { ConfigOptions, OptionalOptions, eslintConfig };
|