Skip to content

Commit a0385d0

Browse files
committed
enable rules from [email protected]
1 parent ac784c0 commit a0385d0

File tree

1 file changed

+25
-2
lines changed

1 file changed

+25
-2
lines changed

tests/eslint/eslint.config.js

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1252,8 +1252,19 @@ const forbidES2024BuiltIns = {
12521252
};
12531253

12541254
const forbidES2025BuiltIns = {
1255-
// disallow duplicate named capture groups
1256-
'es/no-regexp-duplicate-named-capturing-groups': ERROR,
1255+
'es/no-iterator': ERROR,
1256+
'es/no-iterator-prototype-drop': ERROR,
1257+
'es/no-iterator-prototype-every': ERROR,
1258+
'es/no-iterator-prototype-filter': ERROR,
1259+
'es/no-iterator-prototype-find': ERROR,
1260+
'es/no-iterator-prototype-flatmap': ERROR,
1261+
'es/no-iterator-prototype-foreach': ERROR,
1262+
'es/no-iterator-prototype-map': ERROR,
1263+
'es/no-iterator-prototype-reduce': ERROR,
1264+
'es/no-iterator-prototype-some': ERROR,
1265+
'es/no-iterator-prototype-take': ERROR,
1266+
'es/no-iterator-prototype-toarray': ERROR,
1267+
'es/no-promise-try': ERROR,
12571268
'es/no-set-prototype-difference': ERROR,
12581269
'es/no-set-prototype-intersection': ERROR,
12591270
'es/no-set-prototype-isdisjointfrom': ERROR,
@@ -1298,6 +1309,15 @@ const forbidES2023IntlBuiltIns = {
12981309
'es/no-intl-pluralrules-prototype-selectrange': ERROR,
12991310
};
13001311

1312+
const forbidSomeES2025Syntax = {
1313+
'es/no-regexp-duplicate-named-capturing-groups': ERROR,
1314+
'es/no-regexp-modifiers': ERROR,
1315+
'es/no-import-attributes': ERROR,
1316+
'es/no-dynamic-import-options': ERROR,
1317+
'es/no-trailing-dynamic-import-commas': ERROR,
1318+
'es/no-json-modules': ERROR,
1319+
};
1320+
13011321
const forbidModernBuiltIns = {
13021322
...forbidESAnnexBBuiltIns,
13031323
...forbidES5BuiltIns,
@@ -1363,6 +1383,7 @@ const transpiledAndPolyfilled = {
13631383
'regexp/prefer-lookaround': [ERROR, { lookbehind: false, strictTypes: true }],
13641384
// enforce using named capture group in regular expression
13651385
'regexp/prefer-named-capture-group': OFF,
1386+
...forbidSomeES2025Syntax,
13661387
};
13671388

13681389
const nodePackages = {
@@ -1412,6 +1433,7 @@ const nodePackages = {
14121433
...forbidES2021IntlBuiltIns,
14131434
...forbidES2022IntlBuiltIns,
14141435
...forbidES2023IntlBuiltIns,
1436+
...forbidSomeES2025Syntax,
14151437
};
14161438

14171439
const nodeDev = {
@@ -1428,6 +1450,7 @@ const nodeDev = {
14281450
'redos/no-vulnerable': OFF,
14291451
// prefer top-level await
14301452
'unicorn/prefer-top-level-await': ERROR,
1453+
...forbidSomeES2025Syntax,
14311454
};
14321455

14331456
const tests = {

0 commit comments

Comments
 (0)