Skip to content

Commit 445e416

Browse files
authored
feat: add support for decorator metadata in scope analysis and in consistent-type-imports (#2751)
Fixes #2559
1 parent d02a40d commit 445e416

26 files changed

+3432
-272
lines changed

packages/eslint-plugin/docs/rules/consistent-type-imports.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const defaultOptions: Options = {
2525

2626
This option defines the expected import kind for type-only imports. Valid values for `prefer` are:
2727

28-
- `type-imports` will enforce that you always use `import type Foo from '...'`. It is default.
28+
- `type-imports` will enforce that you always use `import type Foo from '...'` except referenced by metadata of decorators. It is default.
2929
- `no-type-imports` will enforce that you always use `import Foo from '...'`.
3030

3131
Examples of **correct** code with `{prefer: 'type-imports'}`, and **incorrect** code with `{prefer: 'no-type-imports'}`.

0 commit comments

Comments
 (0)