@polariens/kitsune-lint 1.0.0-rc.13 → 1.0.0-rc.14
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/eslint/configs/typescript.mjs +1 -1
- package/eslint/index.mjs +14 -1
- package/package.json +1 -1
|
@@ -207,7 +207,7 @@ export function typescript(options = {}) {
|
|
|
207
207
|
},
|
|
208
208
|
{
|
|
209
209
|
// Disable export/import default in router plugin and config files
|
|
210
|
-
files: ['src/router
|
|
210
|
+
files: ['src/router/index.ts', '**/*.d.{ts,js}', '**/*.config.{ts,js}'],
|
|
211
211
|
rules: {
|
|
212
212
|
'no-restricted-syntax': 'off',
|
|
213
213
|
},
|
package/eslint/index.mjs
CHANGED
|
@@ -83,5 +83,18 @@ export async function createKitsuneConfig(options = {}) {
|
|
|
83
83
|
|
|
84
84
|
configs.push(...extend);
|
|
85
85
|
|
|
86
|
-
|
|
86
|
+
// Mover blocos que desabilitam 'no-restricted-syntax' para o fim da lista
|
|
87
|
+
// para garantir que eles se sobreponham corretamente a qualquer regra geral ativada por outros módulos.
|
|
88
|
+
const generalConfigs = [];
|
|
89
|
+
const overrideConfigs = [];
|
|
90
|
+
for (const config of configs) {
|
|
91
|
+
const isRestrictedSyntaxOff = config.rules && config.rules['no-restricted-syntax'] === 'off';
|
|
92
|
+
if (isRestrictedSyntaxOff) {
|
|
93
|
+
overrideConfigs.push(config);
|
|
94
|
+
} else {
|
|
95
|
+
generalConfigs.push(config);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
return mergeConfigRules([...generalConfigs, ...overrideConfigs]);
|
|
87
100
|
}
|
package/package.json
CHANGED