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

Commit 70c5617

Browse files
committed
Add rule @typescript-eslint/indent
1 parent 5e054a0 commit 70c5617

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import type { IndentOptions } from '../eslint/indent';
2+
import type { RuleConfig } from '../rule-config';
3+
4+
/**
5+
* Enforce consistent indentation.
6+
*
7+
* @see [indent](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/indent.md)
8+
*/
9+
export type IndentRuleConfig = RuleConfig<IndentOptions>;
10+
11+
/**
12+
* Enforce consistent indentation.
13+
*
14+
* @see [indent](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/indent.md)
15+
*/
16+
export interface IndentRule {
17+
/**
18+
* Enforce consistent indentation.
19+
*
20+
* @see [indent](https://github.com/typescript-eslint/typescript-eslint/blob/master/packages/eslint-plugin/docs/rules/indent.md)
21+
*/
22+
'@typescript-eslint/indent': IndentRuleConfig;
23+
}

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import type { BanTsCommentRule } from './ban-ts-comment';
55
import type { BanTypesRule } from './ban-types';
66
import type { ConsistentTypeAssertionsRule } from './consistent-type-assertions';
77
import type { ExplicitFunctionReturnTypeRule } from './explicit-function-return-type';
8+
import type { IndentRule } from './indent';
89
import type { InterfaceNamePrefixRule } from './interface-name-prefix';
910
import type { MemberOrderingRule } from './member-ordering';
1011
import type { NoExplicitAnyRule } from './no-explicit-any';
@@ -29,6 +30,7 @@ export type TypeScriptEslintRules = AdjacentOverloadSignaturesRule &
2930
BanTypesRule &
3031
ConsistentTypeAssertionsRule &
3132
ExplicitFunctionReturnTypeRule &
33+
IndentRule &
3234
InterfaceNamePrefixRule &
3335
MemberOrderingRule &
3436
NoExplicitAnyRule &

0 commit comments

Comments
 (0)