Skip to content

Commit 4c1ef54

Browse files
feat: more tweaks
1 parent c57b890 commit 4c1ef54

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

src/configs/node.ts

+11-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { type ESLint } from "eslint";
22

3-
import { GLOB_MJS, GLOB_TS } from "../globs";
3+
import { GLOB_DTS, GLOB_MJS, GLOB_TS, GLOB_TSX } from "../globs";
44
import { type FlatConfigItem } from "../types";
55
import { loadPackages } from "../utils";
66

@@ -60,7 +60,6 @@ export async function node(): Promise<FlatConfigItem[]> {
6060
],
6161
"node/no-sync": "error",
6262
"node/no-unpublished-import": "warn",
63-
"node/no-unsupported-features/es-syntax": "off",
6463
"node/prefer-global/buffer": ["error", "never"],
6564
"node/prefer-global/console": ["error", "always"],
6665
"node/prefer-global/process": ["error", "always"],
@@ -73,10 +72,19 @@ export async function node(): Promise<FlatConfigItem[]> {
7372
},
7473
},
7574
{
76-
files: [GLOB_TS, GLOB_MJS],
75+
files: [GLOB_TS, GLOB_TSX, GLOB_DTS, GLOB_MJS],
7776
rules: {
7877
"node/no-unsupported-features/es-syntax": "off",
7978
},
8079
},
80+
{
81+
files: [GLOB_TS, GLOB_TSX, GLOB_DTS],
82+
rules: {
83+
"node/no-extraneous-import": "off",
84+
"node/no-missing-import": "off",
85+
"node/no-restricted-import": "off",
86+
"node/no-restricted-require": "off",
87+
},
88+
},
8189
];
8290
}

0 commit comments

Comments
 (0)