This repository was archived by the owner on Mar 7, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +40
-0
lines changed
src/rules/typescript-eslint Expand file tree Collapse file tree 2 files changed +40
-0
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ import type { NoConfusingVoidExpressionRule } from './no-confusing-void-expressi
38
38
import type { NoDupeClassMembersRule } from './no-dupe-class-members' ;
39
39
import type { NoDuplicateEnumValuesRule } from './no-duplicate-enum-values' ;
40
40
import type { NoDuplicateImportsRule } from './no-duplicate-imports' ;
41
+ import type { NoDuplicateTypeConstituentsRule } from './no-duplicate-type-constituents' ;
41
42
import type { NoDynamicDeleteRule } from './no-dynamic-delete' ;
42
43
import type { NoEmptyFunctionRule } from './no-empty-function' ;
43
44
import type { NoEmptyInterfaceRule } from './no-empty-interface' ;
@@ -176,6 +177,7 @@ export type TypeScriptRules = AdjacentOverloadSignaturesRule &
176
177
NoDupeClassMembersRule &
177
178
NoDuplicateEnumValuesRule &
178
179
NoDuplicateImportsRule &
180
+ NoDuplicateTypeConstituentsRule &
179
181
NoDynamicDeleteRule &
180
182
NoEmptyFunctionRule &
181
183
NoEmptyInterfaceRule &
Original file line number Diff line number Diff line change
1
+ import type { RuleConfig } from '../rule-config' ;
2
+
3
+ /**
4
+ * Option.
5
+ */
6
+ export interface NoDuplicateTypeConstituentsOption {
7
+ ignoreIntersections ?: boolean ;
8
+ ignoreUnions ?: boolean ;
9
+ }
10
+
11
+ /**
12
+ * Options.
13
+ */
14
+ export type NoDuplicateTypeConstituentsOptions = [
15
+ NoDuplicateTypeConstituentsOption ?,
16
+ ] ;
17
+
18
+ /**
19
+ * Disallow duplicate constituents of union or intersection types.
20
+ *
21
+ * @see [no-duplicate-type-constituents](https://typescript-eslint.io/rules/no-duplicate-type-constituents)
22
+ */
23
+ export type NoDuplicateTypeConstituentsRuleConfig =
24
+ RuleConfig < NoDuplicateTypeConstituentsOptions > ;
25
+
26
+ /**
27
+ * Disallow duplicate constituents of union or intersection types.
28
+ *
29
+ * @see [no-duplicate-type-constituents](https://typescript-eslint.io/rules/no-duplicate-type-constituents)
30
+ */
31
+ export interface NoDuplicateTypeConstituentsRule {
32
+ /**
33
+ * Disallow duplicate constituents of union or intersection types.
34
+ *
35
+ * @see [no-duplicate-type-constituents](https://typescript-eslint.io/rules/no-duplicate-type-constituents)
36
+ */
37
+ '@typescript-eslint/no-duplicate-type-constituents' : NoDuplicateTypeConstituentsRuleConfig ;
38
+ }
You can’t perform that action at this time.
0 commit comments