Skip to content

Commit 6848158

Browse files
feat: cleanup main types
1 parent 786e56e commit 6848158

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

index.d.ts

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,15 @@
1-
import { type Linter, type Rule } from "eslint";
1+
import type { Linter, Rule } from "eslint";
2+
3+
type SupportedConfigs = 'all' | 'recommended';
24

35
declare const plugin: {
46
meta: {
57
name: string;
68
version: string;
79
};
8-
configs: {
9-
all: Linter.LegacyConfig;
10-
recommended: Linter.LegacyConfig;
11-
"flat/all": Linter.FlatConfig;
12-
"flat/recommended": Linter.FlatConfig;
13-
};
14-
rules: {
15-
[key: string]: Rule.RuleModule;
16-
};
10+
configs: Record<SupportedConfigs, Linter.LegacyConfig> &
11+
Record<`flat/${SupportedConfigs}`, Linter.FlatConfig>;
12+
rules: Record<string, Rule.RuleModule>;
1713
};
1814

1915
export = plugin;

0 commit comments

Comments
 (0)