Skip to content
This repository was archived by the owner on Mar 7, 2025. It is now read-only.

Commit 6df08d1

Browse files
committed
Update typescript-eslint rules
1 parent ed7470a commit 6df08d1

File tree

2 files changed

+40
-0
lines changed

2 files changed

+40
-0
lines changed

src/rules/typescript-eslint/index.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ import type { NoConfusingVoidExpressionRule } from './no-confusing-void-expressi
3838
import type { NoDupeClassMembersRule } from './no-dupe-class-members';
3939
import type { NoDuplicateEnumValuesRule } from './no-duplicate-enum-values';
4040
import type { NoDuplicateImportsRule } from './no-duplicate-imports';
41+
import type { NoDuplicateTypeConstituentsRule } from './no-duplicate-type-constituents';
4142
import type { NoDynamicDeleteRule } from './no-dynamic-delete';
4243
import type { NoEmptyFunctionRule } from './no-empty-function';
4344
import type { NoEmptyInterfaceRule } from './no-empty-interface';
@@ -176,6 +177,7 @@ export type TypeScriptRules = AdjacentOverloadSignaturesRule &
176177
NoDupeClassMembersRule &
177178
NoDuplicateEnumValuesRule &
178179
NoDuplicateImportsRule &
180+
NoDuplicateTypeConstituentsRule &
179181
NoDynamicDeleteRule &
180182
NoEmptyFunctionRule &
181183
NoEmptyInterfaceRule &
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
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+
}

0 commit comments

Comments
 (0)