From 1bc2c80fd01f398038ce2acb21377d2bbe8dc784 Mon Sep 17 00:00:00 2001 From: Brad Zacher Date: Thu, 26 May 2022 22:10:51 -0700 Subject: [PATCH 1/2] chore(website): automate the addition of rule attributes to the website --- packages/eslint-plugin/docs/rules/TEMPLATE.md | 8 - .../rules/adjacent-overload-signatures.md | 8 - .../eslint-plugin/docs/rules/array-type.md | 8 - .../docs/rules/await-thenable.md | 8 - .../docs/rules/ban-ts-comment.md | 8 - .../docs/rules/ban-tslint-comment.md | 8 - .../eslint-plugin/docs/rules/ban-types.md | 8 - .../eslint-plugin/docs/rules/brace-style.md | 8 - .../rules/class-literal-property-style.md | 8 - .../eslint-plugin/docs/rules/comma-dangle.md | 8 - .../eslint-plugin/docs/rules/comma-spacing.md | 8 - .../rules/consistent-indexed-object-style.md | 8 - .../docs/rules/consistent-type-assertions.md | 8 - .../docs/rules/consistent-type-definitions.md | 8 - .../docs/rules/consistent-type-exports.md | 8 - .../docs/rules/consistent-type-imports.md | 8 - .../docs/rules/default-param-last.md | 8 - .../eslint-plugin/docs/rules/dot-notation.md | 8 - .../rules/explicit-function-return-type.md | 8 - .../rules/explicit-member-accessibility.md | 8 - .../rules/explicit-module-boundary-types.md | 8 - .../docs/rules/func-call-spacing.md | 8 - packages/eslint-plugin/docs/rules/indent.md | 8 - .../docs/rules/init-declarations.md | 8 - .../docs/rules/keyword-spacing.md | 8 - .../docs/rules/lines-between-class-members.md | 8 - .../docs/rules/member-delimiter-style.md | 8 - .../docs/rules/member-ordering.md | 8 - .../docs/rules/method-signature-style.md | 8 - .../docs/rules/naming-convention.md | 8 - .../docs/rules/no-array-constructor.md | 8 - .../docs/rules/no-base-to-string.md | 8 - .../rules/no-confusing-non-null-assertion.md | 8 - .../rules/no-confusing-void-expression.md | 8 - .../docs/rules/no-dupe-class-members.md | 8 - .../docs/rules/no-duplicate-enum-values.md | 8 - .../docs/rules/no-duplicate-imports.md | 8 - .../docs/rules/no-dynamic-delete.md | 8 - .../docs/rules/no-empty-function.md | 8 - .../docs/rules/no-empty-interface.md | 8 - .../docs/rules/no-explicit-any.md | 8 - .../docs/rules/no-extra-non-null-assertion.md | 8 - .../docs/rules/no-extra-parens.md | 8 - .../eslint-plugin/docs/rules/no-extra-semi.md | 8 - .../docs/rules/no-extraneous-class.md | 8 - .../docs/rules/no-floating-promises.md | 8 - .../docs/rules/no-for-in-array.md | 8 - .../docs/rules/no-implicit-any-catch.md | 8 - .../docs/rules/no-implied-eval.md | 8 - .../docs/rules/no-inferrable-types.md | 8 - .../docs/rules/no-invalid-this.md | 8 - .../docs/rules/no-invalid-void-type.md | 8 - .../eslint-plugin/docs/rules/no-loop-func.md | 8 - .../docs/rules/no-loss-of-precision.md | 8 - .../docs/rules/no-magic-numbers.md | 8 - .../rules/no-meaningless-void-operator.md | 8 - .../docs/rules/no-misused-new.md | 8 - .../docs/rules/no-misused-promises.md | 8 - .../eslint-plugin/docs/rules/no-namespace.md | 8 - ...no-non-null-asserted-nullish-coalescing.md | 8 - .../no-non-null-asserted-optional-chain.md | 8 - .../docs/rules/no-non-null-assertion.md | 8 - .../docs/rules/no-parameter-properties.md | 8 - .../eslint-plugin/docs/rules/no-redeclare.md | 8 - .../rules/no-redundant-type-constituents.md | 8 - .../docs/rules/no-require-imports.md | 8 - .../docs/rules/no-restricted-imports.md | 8 - .../eslint-plugin/docs/rules/no-shadow.md | 8 - .../eslint-plugin/docs/rules/no-this-alias.md | 8 - .../docs/rules/no-throw-literal.md | 8 - .../eslint-plugin/docs/rules/no-type-alias.md | 8 - .../no-unnecessary-boolean-literal-compare.md | 8 - .../docs/rules/no-unnecessary-condition.md | 8 - .../docs/rules/no-unnecessary-qualifier.md | 8 - .../rules/no-unnecessary-type-arguments.md | 8 - .../rules/no-unnecessary-type-assertion.md | 8 - .../rules/no-unnecessary-type-constraint.md | 8 - .../docs/rules/no-unsafe-argument.md | 8 - .../docs/rules/no-unsafe-assignment.md | 8 - .../docs/rules/no-unsafe-call.md | 8 - .../docs/rules/no-unsafe-member-access.md | 8 - .../docs/rules/no-unsafe-return.md | 8 - .../docs/rules/no-unused-expressions.md | 8 - .../docs/rules/no-unused-vars.md | 8 - .../docs/rules/no-use-before-define.md | 8 - .../docs/rules/no-useless-constructor.md | 8 - .../docs/rules/no-useless-empty-export.md | 8 - .../docs/rules/no-var-requires.md | 8 - .../non-nullable-type-assertion-style.md | 8 - .../docs/rules/object-curly-spacing.md | 8 - .../rules/padding-line-between-statements.md | 8 - .../docs/rules/parameter-properties.md | 8 - .../docs/rules/prefer-as-const.md | 8 - .../docs/rules/prefer-enum-initializers.md | 8 - .../eslint-plugin/docs/rules/prefer-for-of.md | 8 - .../docs/rules/prefer-function-type.md | 8 - .../docs/rules/prefer-includes.md | 8 - .../docs/rules/prefer-literal-enum-member.md | 8 - .../docs/rules/prefer-namespace-keyword.md | 8 - .../docs/rules/prefer-nullish-coalescing.md | 8 - .../docs/rules/prefer-optional-chain.md | 8 - .../rules/prefer-readonly-parameter-types.md | 8 - .../docs/rules/prefer-readonly.md | 8 - .../rules/prefer-reduce-type-parameter.md | 8 - .../docs/rules/prefer-regexp-exec.md | 8 - .../docs/rules/prefer-return-this-type.md | 8 - .../rules/prefer-string-starts-ends-with.md | 8 - .../docs/rules/prefer-ts-expect-error.md | 8 - .../docs/rules/promise-function-async.md | 8 - packages/eslint-plugin/docs/rules/quotes.md | 8 - .../docs/rules/require-array-sort-compare.md | 8 - .../eslint-plugin/docs/rules/require-await.md | 8 - .../docs/rules/restrict-plus-operands.md | 8 - .../rules/restrict-template-expressions.md | 8 - .../eslint-plugin/docs/rules/return-await.md | 8 - packages/eslint-plugin/docs/rules/semi.md | 8 - .../sort-type-union-intersection-members.md | 8 - .../docs/rules/space-before-blocks.md | 8 - .../docs/rules/space-before-function-paren.md | 8 - .../docs/rules/space-infix-ops.md | 8 - .../docs/rules/strict-boolean-expressions.md | 8 - .../docs/rules/switch-exhaustiveness-check.md | 8 - .../docs/rules/triple-slash-reference.md | 8 - .../docs/rules/type-annotation-spacing.md | 8 - packages/eslint-plugin/docs/rules/typedef.md | 8 - .../docs/rules/unbound-method.md | 8 - .../docs/rules/unified-signatures.md | 8 - packages/eslint-plugin/tests/docs.test.ts | 43 ---- packages/website/docusaurus.config.js | 199 +---------------- packages/website/docusaurusConfig.ts | 192 +++++++++++++++++ packages/website/package.json | 1 + .../plugins/add-rule-attributes-list.ts | 203 ++++++++++++++++++ packages/website/src/css/custom.css | 5 + packages/website/tsconfig.json | 2 +- .../typings/remark-docusaurus-tabs.d.ts | 5 + 135 files changed, 415 insertions(+), 1251 deletions(-) create mode 100644 packages/website/docusaurusConfig.ts create mode 100644 packages/website/plugins/add-rule-attributes-list.ts create mode 100644 packages/website/typings/remark-docusaurus-tabs.d.ts diff --git a/packages/eslint-plugin/docs/rules/TEMPLATE.md b/packages/eslint-plugin/docs/rules/TEMPLATE.md index c2c7136fe3e7..7528ad501a31 100644 --- a/packages/eslint-plugin/docs/rules/TEMPLATE.md +++ b/packages/eslint-plugin/docs/rules/TEMPLATE.md @@ -51,11 +51,3 @@ const defaultOptions: Options = { To fill out: why wouldn't you want to use this rule? For example if this rule requires a feature released in a certain TS version. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/adjacent-overload-signatures.md b/packages/eslint-plugin/docs/rules/adjacent-overload-signatures.md index 840fbcdc8d40..26589d7d06ba 100644 --- a/packages/eslint-plugin/docs/rules/adjacent-overload-signatures.md +++ b/packages/eslint-plugin/docs/rules/adjacent-overload-signatures.md @@ -104,11 +104,3 @@ If you don't care about the general structure of the code, then you will not nee ## Related To - TSLint: [adjacent-overload-signatures](https://palantir.github.io/tslint/rules/adjacent-overload-signatures/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/array-type.md b/packages/eslint-plugin/docs/rules/array-type.md index 6755f3d1975a..5898344fe3e3 100644 --- a/packages/eslint-plugin/docs/rules/array-type.md +++ b/packages/eslint-plugin/docs/rules/array-type.md @@ -122,11 +122,3 @@ This matrix lists all possible option combinations and their expected results fo ## Related To - TSLint: [array-type](https://palantir.github.io/tslint/rules/array-type/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/await-thenable.md b/packages/eslint-plugin/docs/rules/await-thenable.md index f308a202e621..10e3fee45cec 100644 --- a/packages/eslint-plugin/docs/rules/await-thenable.md +++ b/packages/eslint-plugin/docs/rules/await-thenable.md @@ -50,11 +50,3 @@ This is generally not preferred, but can sometimes be useful for visual consiste ## Related To - TSLint: ['await-promise'](https://palantir.github.io/tslint/rules/await-promise) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/ban-ts-comment.md b/packages/eslint-plugin/docs/rules/ban-ts-comment.md index 8f521e919fd3..4ecec074fd77 100644 --- a/packages/eslint-plugin/docs/rules/ban-ts-comment.md +++ b/packages/eslint-plugin/docs/rules/ban-ts-comment.md @@ -142,11 +142,3 @@ If you want to use all of the TypeScript directives. ## Related To - TSLint: [ban-ts-ignore](https://palantir.github.io/tslint/rules/ban-ts-ignore/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/ban-tslint-comment.md b/packages/eslint-plugin/docs/rules/ban-tslint-comment.md index 6714000aba8d..a4b726a7142a 100644 --- a/packages/eslint-plugin/docs/rules/ban-tslint-comment.md +++ b/packages/eslint-plugin/docs/rules/ban-tslint-comment.md @@ -46,11 +46,3 @@ This rule is not configurable. ## When Not To Use It If you are still using TSLint. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/ban-types.md b/packages/eslint-plugin/docs/rules/ban-types.md index 23cf2f98db9f..024aa627d1fe 100644 --- a/packages/eslint-plugin/docs/rules/ban-types.md +++ b/packages/eslint-plugin/docs/rules/ban-types.md @@ -201,11 +201,3 @@ const curly2: Record<'a', string> = { a: 'string' }; ## Related To - TSLint: [ban-types](https://palantir.github.io/tslint/rules/ban-types) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/brace-style.md b/packages/eslint-plugin/docs/rules/brace-style.md index c9a259cdb7ac..bd53499e460a 100644 --- a/packages/eslint-plugin/docs/rules/brace-style.md +++ b/packages/eslint-plugin/docs/rules/brace-style.md @@ -26,11 +26,3 @@ See [`eslint/brace-style` options](https://eslint.org/docs/rules/brace-style#opt Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/brace-style.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/class-literal-property-style.md b/packages/eslint-plugin/docs/rules/class-literal-property-style.md index 8dab1dc263b9..112f76547e73 100644 --- a/packages/eslint-plugin/docs/rules/class-literal-property-style.md +++ b/packages/eslint-plugin/docs/rules/class-literal-property-style.md @@ -108,11 +108,3 @@ class Mx { When you have no strong preference, or do not wish to enforce a particular style for how literal values are exposed by your classes. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/comma-dangle.md b/packages/eslint-plugin/docs/rules/comma-dangle.md index 2ddd7f66ca0b..c34c25e7f023 100644 --- a/packages/eslint-plugin/docs/rules/comma-dangle.md +++ b/packages/eslint-plugin/docs/rules/comma-dangle.md @@ -38,11 +38,3 @@ This rule has a string option and an object option. Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/comma-dangle.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/comma-spacing.md b/packages/eslint-plugin/docs/rules/comma-spacing.md index e598c20fcf9e..7fa6056759dc 100644 --- a/packages/eslint-plugin/docs/rules/comma-spacing.md +++ b/packages/eslint-plugin/docs/rules/comma-spacing.md @@ -26,11 +26,3 @@ See [`eslint/comma-spacing` options](https://eslint.org/docs/rules/comma-spacing Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/comma-spacing.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/consistent-indexed-object-style.md b/packages/eslint-plugin/docs/rules/consistent-indexed-object-style.md index 6e02816695df..7fc96ad8c7ed 100644 --- a/packages/eslint-plugin/docs/rules/consistent-indexed-object-style.md +++ b/packages/eslint-plugin/docs/rules/consistent-indexed-object-style.md @@ -82,11 +82,3 @@ type Foo = { [key: string]: unknown; }; ``` - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/consistent-type-assertions.md b/packages/eslint-plugin/docs/rules/consistent-type-assertions.md index 6cf35c5c160b..609ad5dac41f 100644 --- a/packages/eslint-plugin/docs/rules/consistent-type-assertions.md +++ b/packages/eslint-plugin/docs/rules/consistent-type-assertions.md @@ -116,11 +116,3 @@ If you do not want to enforce consistent type assertions. - TSLint: [no-angle-bracket-type-assertion](https://palantir.github.io/tslint/rules/no-angle-bracket-type-assertion/) - TSLint: [no-object-literal-type-assertion](https://palantir.github.io/tslint/rules/no-object-literal-type-assertion/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/consistent-type-definitions.md b/packages/eslint-plugin/docs/rules/consistent-type-definitions.md index 37f69af6c7a3..2da964dff7aa 100644 --- a/packages/eslint-plugin/docs/rules/consistent-type-definitions.md +++ b/packages/eslint-plugin/docs/rules/consistent-type-definitions.md @@ -84,11 +84,3 @@ If you specifically want to use an interface or type literal for stylistic reaso ## Related To - TSLint: [interface-over-type-literal](https://palantir.github.io/tslint/rules/interface-over-type-literal/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/consistent-type-exports.md b/packages/eslint-plugin/docs/rules/consistent-type-exports.md index f38230dd88e5..bd10a616261c 100644 --- a/packages/eslint-plugin/docs/rules/consistent-type-exports.md +++ b/packages/eslint-plugin/docs/rules/consistent-type-exports.md @@ -109,11 +109,3 @@ export { Button, type ButtonProps } from 'some-library'; - If you are using a TypeScript version less than 3.8, then you will not be able to use this rule as type exports are not supported. - If you specifically want to use both export kinds for stylistic reasons, you can disable this rule. - If you use `--isolatedModules` the compiler would error if a type is not re-exported using `export type`. If you also don't wish to enforce one style over the other, you can disable this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/consistent-type-imports.md b/packages/eslint-plugin/docs/rules/consistent-type-imports.md index f3d96bec5ceb..47022b04ec57 100644 --- a/packages/eslint-plugin/docs/rules/consistent-type-imports.md +++ b/packages/eslint-plugin/docs/rules/consistent-type-imports.md @@ -64,11 +64,3 @@ const x: import('Bar') = 1; - If you are not using TypeScript 3.8 (or greater), then you will not be able to use this rule, as type-only imports are not allowed. - If you specifically want to use both import kinds for stylistic reasons, you can disable this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/default-param-last.md b/packages/eslint-plugin/docs/rules/default-param-last.md index 830d2828c012..8cc7413ad844 100644 --- a/packages/eslint-plugin/docs/rules/default-param-last.md +++ b/packages/eslint-plugin/docs/rules/default-param-last.md @@ -62,11 +62,3 @@ See [`eslint/default-param-last` options](https://eslint.org/docs/rules/default- Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/default-param-last.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/dot-notation.md b/packages/eslint-plugin/docs/rules/dot-notation.md index 1256f2004fed..3de7e0750fc4 100644 --- a/packages/eslint-plugin/docs/rules/dot-notation.md +++ b/packages/eslint-plugin/docs/rules/dot-notation.md @@ -87,11 +87,3 @@ If the TypeScript compiler option `noPropertyAccessFromIndexSignature` is set to Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/dot-notation.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/explicit-function-return-type.md b/packages/eslint-plugin/docs/rules/explicit-function-return-type.md index 8faf8aab503a..1538d71669a8 100644 --- a/packages/eslint-plugin/docs/rules/explicit-function-return-type.md +++ b/packages/eslint-plugin/docs/rules/explicit-function-return-type.md @@ -290,11 +290,3 @@ you will not need this rule. ## Further Reading - TypeScript [Functions](https://www.typescriptlang.org/docs/handbook/functions.html#function-types) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/explicit-member-accessibility.md b/packages/eslint-plugin/docs/rules/explicit-member-accessibility.md index 7570e6e4667a..bf1f12565841 100644 --- a/packages/eslint-plugin/docs/rules/explicit-member-accessibility.md +++ b/packages/eslint-plugin/docs/rules/explicit-member-accessibility.md @@ -348,11 +348,3 @@ If you think defaulting to public is a good default, then you should consider us ## Related To - TSLint: [member-access](http://palantir.github.io/tslint/rules/member-access/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/explicit-module-boundary-types.md b/packages/eslint-plugin/docs/rules/explicit-module-boundary-types.md index 26809892e678..803253ecc99a 100644 --- a/packages/eslint-plugin/docs/rules/explicit-module-boundary-types.md +++ b/packages/eslint-plugin/docs/rules/explicit-module-boundary-types.md @@ -285,11 +285,3 @@ If you wish to make sure all functions have explicit return types, as opposed to ## Further Reading - TypeScript [Functions](https://www.typescriptlang.org/docs/handbook/functions.html#function-types) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/func-call-spacing.md b/packages/eslint-plugin/docs/rules/func-call-spacing.md index f968cf45d2c6..e85fc5230fe4 100644 --- a/packages/eslint-plugin/docs/rules/func-call-spacing.md +++ b/packages/eslint-plugin/docs/rules/func-call-spacing.md @@ -26,11 +26,3 @@ See [`eslint/func-call-spacing` options](https://eslint.org/docs/rules/func-call Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/func-call-spacing.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/indent.md b/packages/eslint-plugin/docs/rules/indent.md index aeee0ffcc121..33524a34239e 100644 --- a/packages/eslint-plugin/docs/rules/indent.md +++ b/packages/eslint-plugin/docs/rules/indent.md @@ -30,11 +30,3 @@ See [`eslint/indent` options](https://eslint.org/docs/rules/indent#options). Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/indent.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/init-declarations.md b/packages/eslint-plugin/docs/rules/init-declarations.md index 895aa0d4dfd7..6361bd568057 100644 --- a/packages/eslint-plugin/docs/rules/init-declarations.md +++ b/packages/eslint-plugin/docs/rules/init-declarations.md @@ -26,11 +26,3 @@ See [`eslint/init-declarations` options](https://eslint.org/docs/rules/init-decl Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/init-declarations.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/keyword-spacing.md b/packages/eslint-plugin/docs/rules/keyword-spacing.md index 446cdab3e967..59221acc47a9 100644 --- a/packages/eslint-plugin/docs/rules/keyword-spacing.md +++ b/packages/eslint-plugin/docs/rules/keyword-spacing.md @@ -26,11 +26,3 @@ See [`eslint/keyword-spacing` options](https://eslint.org/docs/rules/keyword-spa Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/keyword-spacing.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/lines-between-class-members.md b/packages/eslint-plugin/docs/rules/lines-between-class-members.md index 769e5f8d268e..9955b2fce8f9 100644 --- a/packages/eslint-plugin/docs/rules/lines-between-class-members.md +++ b/packages/eslint-plugin/docs/rules/lines-between-class-members.md @@ -77,11 +77,3 @@ class foo { Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/lines-between-class-members.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/member-delimiter-style.md b/packages/eslint-plugin/docs/rules/member-delimiter-style.md index 741f34171be3..aa60055e7d47 100644 --- a/packages/eslint-plugin/docs/rules/member-delimiter-style.md +++ b/packages/eslint-plugin/docs/rules/member-delimiter-style.md @@ -208,11 +208,3 @@ type FooBar = { name: string; greet(): string } ## When Not To Use It If you don't care about enforcing a consistent member delimiter in interfaces and type literals, then you will not need this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/member-ordering.md b/packages/eslint-plugin/docs/rules/member-ordering.md index 588fd8ada36a..9fe1ee29557b 100644 --- a/packages/eslint-plugin/docs/rules/member-ordering.md +++ b/packages/eslint-plugin/docs/rules/member-ordering.md @@ -1163,11 +1163,3 @@ If you don't care about the general order of your members, then you will not nee ## Related To - TSLint: [member-ordering](https://palantir.github.io/tslint/rules/member-ordering/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/method-signature-style.md b/packages/eslint-plugin/docs/rules/method-signature-style.md index 1c3a8a0cbcde..53a6d3e17a02 100644 --- a/packages/eslint-plugin/docs/rules/method-signature-style.md +++ b/packages/eslint-plugin/docs/rules/method-signature-style.md @@ -104,11 +104,3 @@ type T2 = { ## When Not To Use It If you don't want to enforce a particular style for object/interface function types, and/or if you don't use `strictFunctionTypes`, then you don't need this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/naming-convention.md b/packages/eslint-plugin/docs/rules/naming-convention.md index 7fc4729b966e..9032119ca40d 100644 --- a/packages/eslint-plugin/docs/rules/naming-convention.md +++ b/packages/eslint-plugin/docs/rules/naming-convention.md @@ -700,11 +700,3 @@ You can use the `destructured` modifier to match these names, and explicitly set ## When Not To Use It If you do not want to enforce naming conventions for anything. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-array-constructor.md b/packages/eslint-plugin/docs/rules/no-array-constructor.md index 603ba48a5bc8..bb18b418aea8 100644 --- a/packages/eslint-plugin/docs/rules/no-array-constructor.md +++ b/packages/eslint-plugin/docs/rules/no-array-constructor.md @@ -49,11 +49,3 @@ See [`eslint/no-array-constructor` options](https://eslint.org/docs/rules/no-arr Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-array-constructor.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-base-to-string.md b/packages/eslint-plugin/docs/rules/no-base-to-string.md index fde51eccffcd..e9eac5dd91b5 100644 --- a/packages/eslint-plugin/docs/rules/no-base-to-string.md +++ b/packages/eslint-plugin/docs/rules/no-base-to-string.md @@ -89,11 +89,3 @@ let text = `${value}`; If you don't mind `"[object Object]"` in your strings, then you will not need this rule. - [`Object.prototype.toString()` MDN documentation](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/toString) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-confusing-non-null-assertion.md b/packages/eslint-plugin/docs/rules/no-confusing-non-null-assertion.md index 1f5d5b040fd3..67ae758d6223 100644 --- a/packages/eslint-plugin/docs/rules/no-confusing-non-null-assertion.md +++ b/packages/eslint-plugin/docs/rules/no-confusing-non-null-assertion.md @@ -61,11 +61,3 @@ If you don't care about this confusion, then you will not need this rule. ## Further Reading - [`Issue: Easy misunderstanding: "! ==="`](https://github.com/microsoft/TypeScript/issues/37837) in [TypeScript repo](https://github.com/microsoft/TypeScript) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-confusing-void-expression.md b/packages/eslint-plugin/docs/rules/no-confusing-void-expression.md index 88c295ae3bbf..fa6685aae33c 100644 --- a/packages/eslint-plugin/docs/rules/no-confusing-void-expression.md +++ b/packages/eslint-plugin/docs/rules/no-confusing-void-expression.md @@ -151,11 +151,3 @@ Also, if you prefer concise coding style then also don't use it. ## Related To - TSLint: ['no-void-expression'](https://palantir.github.io/tslint/rules/no-void-expression/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-dupe-class-members.md b/packages/eslint-plugin/docs/rules/no-dupe-class-members.md index e0206510e8da..e9fbc1997772 100644 --- a/packages/eslint-plugin/docs/rules/no-dupe-class-members.md +++ b/packages/eslint-plugin/docs/rules/no-dupe-class-members.md @@ -26,11 +26,3 @@ See [`eslint/no-dupe-class-members` options](https://eslint.org/docs/rules/no-du Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-dupe-class-members.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-duplicate-enum-values.md b/packages/eslint-plugin/docs/rules/no-duplicate-enum-values.md index c2fa1db4eec2..bd874f1352a1 100644 --- a/packages/eslint-plugin/docs/rules/no-duplicate-enum-values.md +++ b/packages/eslint-plugin/docs/rules/no-duplicate-enum-values.md @@ -54,11 +54,3 @@ enum E { ``` This rule is not configurable. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-duplicate-imports.md b/packages/eslint-plugin/docs/rules/no-duplicate-imports.md index ae6043468e26..c916e0711568 100644 --- a/packages/eslint-plugin/docs/rules/no-duplicate-imports.md +++ b/packages/eslint-plugin/docs/rules/no-duplicate-imports.md @@ -30,11 +30,3 @@ See [`eslint/no-duplicate-imports` options](https://eslint.org/docs/rules/no-dup Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-duplicate-imports.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-dynamic-delete.md b/packages/eslint-plugin/docs/rules/no-dynamic-delete.md index abbee2acf023..9724dd48fedf 100644 --- a/packages/eslint-plugin/docs/rules/no-dynamic-delete.md +++ b/packages/eslint-plugin/docs/rules/no-dynamic-delete.md @@ -64,11 +64,3 @@ Even repeated minor performance slowdowns likely do not significantly affect you ## Related To - TSLint: [no-dynamic-delete](https://palantir.github.io/tslint/rules/no-dynamic-delete) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-empty-function.md b/packages/eslint-plugin/docs/rules/no-empty-function.md index b25459f6a5d4..a2b20dd5f437 100644 --- a/packages/eslint-plugin/docs/rules/no-empty-function.md +++ b/packages/eslint-plugin/docs/rules/no-empty-function.md @@ -109,11 +109,3 @@ class Foo extends Base { Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-empty-function.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-empty-interface.md b/packages/eslint-plugin/docs/rules/no-empty-interface.md index 508edd1993ce..a3026d2093ff 100644 --- a/packages/eslint-plugin/docs/rules/no-empty-interface.md +++ b/packages/eslint-plugin/docs/rules/no-empty-interface.md @@ -68,11 +68,3 @@ If you don't care about having empty/meaningless interfaces, then you will not n ## Related To - TSLint: [no-empty-interface](https://palantir.github.io/tslint/rules/no-empty-interface/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-explicit-any.md b/packages/eslint-plugin/docs/rules/no-explicit-any.md index aff5ae083e0e..e77b885095c2 100644 --- a/packages/eslint-plugin/docs/rules/no-explicit-any.md +++ b/packages/eslint-plugin/docs/rules/no-explicit-any.md @@ -183,11 +183,3 @@ and you want to be able to specify `any`. ## Related To - TSLint: [no-any](https://palantir.github.io/tslint/rules/no-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-extra-non-null-assertion.md b/packages/eslint-plugin/docs/rules/no-extra-non-null-assertion.md index 78ab63347bfe..9ba95c51e9f9 100644 --- a/packages/eslint-plugin/docs/rules/no-extra-non-null-assertion.md +++ b/packages/eslint-plugin/docs/rules/no-extra-non-null-assertion.md @@ -58,11 +58,3 @@ function foo(bar?: { n: number }) { ``` This rule is not configurable. - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-extra-parens.md b/packages/eslint-plugin/docs/rules/no-extra-parens.md index 4cccccdbe790..272fc21c76b2 100644 --- a/packages/eslint-plugin/docs/rules/no-extra-parens.md +++ b/packages/eslint-plugin/docs/rules/no-extra-parens.md @@ -26,11 +26,3 @@ See [`eslint/no-extra-parens` options](https://eslint.org/docs/rules/no-extra-pa Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-extra-parens.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-extra-semi.md b/packages/eslint-plugin/docs/rules/no-extra-semi.md index 6137b6ca21be..677ee2007803 100644 --- a/packages/eslint-plugin/docs/rules/no-extra-semi.md +++ b/packages/eslint-plugin/docs/rules/no-extra-semi.md @@ -26,11 +26,3 @@ See [`eslint/no-extra-semi` options](https://eslint.org/docs/rules/no-extra-semi Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-extra-semi.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-extraneous-class.md b/packages/eslint-plugin/docs/rules/no-extraneous-class.md index eb229ea655aa..0916632a8806 100644 --- a/packages/eslint-plugin/docs/rules/no-extraneous-class.md +++ b/packages/eslint-plugin/docs/rules/no-extraneous-class.md @@ -84,11 +84,3 @@ team or if you use classes as namespaces. ## Related To [`no-unnecessary-class`](https://palantir.github.io/tslint/rules/no-unnecessary-class/) from TSLint - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-floating-promises.md b/packages/eslint-plugin/docs/rules/no-floating-promises.md index 72ce6e2a5061..1f365ab59a62 100644 --- a/packages/eslint-plugin/docs/rules/no-floating-promises.md +++ b/packages/eslint-plugin/docs/rules/no-floating-promises.md @@ -119,11 +119,3 @@ If you do not use Promise-like values in your codebase, or want to allow them to - [`no-misused-promises`](./no-misused-promises.md) - TSLint: ['no-floating-promises'](https://palantir.github.io/tslint/rules/no-floating-promises/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-for-in-array.md b/packages/eslint-plugin/docs/rules/no-for-in-array.md index 6c4e46b85912..7f86342fa80b 100644 --- a/packages/eslint-plugin/docs/rules/no-for-in-array.md +++ b/packages/eslint-plugin/docs/rules/no-for-in-array.md @@ -61,11 +61,3 @@ If you want to iterate through a loop using the indices in an array as strings, ## Related To - TSLint: ['no-for-in-array'](https://palantir.github.io/tslint/rules/no-for-in-array/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md b/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md index 676ae450532c..7ce49d024d8c 100644 --- a/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md +++ b/packages/eslint-plugin/docs/rules/no-implicit-any-catch.md @@ -82,11 +82,3 @@ If you are not using TypeScript 4.0 (or greater), then you will not be able to u ## Further Reading - [TypeScript 4.0 Release Notes](https://devblogs.microsoft.com/typescript/announcing-typescript-4-0/#unknown-on-catch) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-implied-eval.md b/packages/eslint-plugin/docs/rules/no-implied-eval.md index 5c59f35bb70a..2aa72d170b8a 100644 --- a/packages/eslint-plugin/docs/rules/no-implied-eval.md +++ b/packages/eslint-plugin/docs/rules/no-implied-eval.md @@ -113,11 +113,3 @@ If you want to allow `new Function()` or `setTimeout()`, `setInterval()`, `setIm Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-implied-eval.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-inferrable-types.md b/packages/eslint-plugin/docs/rules/no-inferrable-types.md index 67fd3e2f696b..d27c04821309 100644 --- a/packages/eslint-plugin/docs/rules/no-inferrable-types.md +++ b/packages/eslint-plugin/docs/rules/no-inferrable-types.md @@ -152,11 +152,3 @@ TypeScript [Inference](https://www.typescriptlang.org/docs/handbook/type-inferen ## Related To TSLint: [no-inferrable-types](https://palantir.github.io/tslint/rules/no-inferrable-types/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-invalid-this.md b/packages/eslint-plugin/docs/rules/no-invalid-this.md index 7681bb07f225..e33c3af164fc 100644 --- a/packages/eslint-plugin/docs/rules/no-invalid-this.md +++ b/packages/eslint-plugin/docs/rules/no-invalid-this.md @@ -30,11 +30,3 @@ When you are indifferent as to how your variables are initialized. Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-invalid-this.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-invalid-void-type.md b/packages/eslint-plugin/docs/rules/no-invalid-void-type.md index 44ee066b3686..8465df813c28 100644 --- a/packages/eslint-plugin/docs/rules/no-invalid-void-type.md +++ b/packages/eslint-plugin/docs/rules/no-invalid-void-type.md @@ -130,11 +130,3 @@ or in invalid places, then you don't need this rule. ## Related To - TSLint: [invalid-void](https://palantir.github.io/tslint/rules/invalid-void/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-loop-func.md b/packages/eslint-plugin/docs/rules/no-loop-func.md index 5652dc62fa52..e7255a7d38b5 100644 --- a/packages/eslint-plugin/docs/rules/no-loop-func.md +++ b/packages/eslint-plugin/docs/rules/no-loop-func.md @@ -26,11 +26,3 @@ See [`eslint/no-loop-func` options](https://eslint.org/docs/rules/no-loop-func#o Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-loop-func.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-loss-of-precision.md b/packages/eslint-plugin/docs/rules/no-loss-of-precision.md index 4b1e8c6dd295..7d5c961582aa 100644 --- a/packages/eslint-plugin/docs/rules/no-loss-of-precision.md +++ b/packages/eslint-plugin/docs/rules/no-loss-of-precision.md @@ -23,11 +23,3 @@ Note that this rule requires ESLint v7. Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-loss-of-precision.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-magic-numbers.md b/packages/eslint-plugin/docs/rules/no-magic-numbers.md index ebd724b4a93e..c2b5ed61ebb5 100644 --- a/packages/eslint-plugin/docs/rules/no-magic-numbers.md +++ b/packages/eslint-plugin/docs/rules/no-magic-numbers.md @@ -147,11 +147,3 @@ type Baz = Parameters[2]; Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-magic-numbers.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-meaningless-void-operator.md b/packages/eslint-plugin/docs/rules/no-meaningless-void-operator.md index 58b37b0888c4..e1af64644c4e 100644 --- a/packages/eslint-plugin/docs/rules/no-meaningless-void-operator.md +++ b/packages/eslint-plugin/docs/rules/no-meaningless-void-operator.md @@ -54,11 +54,3 @@ This rule accepts a single object option with the following default configuratio ``` - `checkNever: true` will suggest removing `void` when the argument has type `never`. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-misused-new.md b/packages/eslint-plugin/docs/rules/no-misused-new.md index 735699c6132f..8ae950f77bfb 100644 --- a/packages/eslint-plugin/docs/rules/no-misused-new.md +++ b/packages/eslint-plugin/docs/rules/no-misused-new.md @@ -50,11 +50,3 @@ This rule is not configurable. ## Related To - TSLint: [no-misused-new](https://palantir.github.io/tslint/rules/no-misused-new/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-misused-promises.md b/packages/eslint-plugin/docs/rules/no-misused-promises.md index 203aefc178e1..6291ad4fe059 100644 --- a/packages/eslint-plugin/docs/rules/no-misused-promises.md +++ b/packages/eslint-plugin/docs/rules/no-misused-promises.md @@ -277,11 +277,3 @@ misuses of them outside of what the TypeScript compiler will check. ## Related To - [`no-floating-promises`](./no-floating-promises.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-namespace.md b/packages/eslint-plugin/docs/rules/no-namespace.md index a6971b5b0b42..7760c5b2e46c 100644 --- a/packages/eslint-plugin/docs/rules/no-namespace.md +++ b/packages/eslint-plugin/docs/rules/no-namespace.md @@ -135,11 +135,3 @@ If you are using the ES2015 module syntax, then you will not need this rule. ## Related To - TSLint: [no-namespace](https://palantir.github.io/tslint/rules/no-namespace/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-non-null-asserted-nullish-coalescing.md b/packages/eslint-plugin/docs/rules/no-non-null-asserted-nullish-coalescing.md index faec85a2e576..0e93789a763a 100644 --- a/packages/eslint-plugin/docs/rules/no-non-null-asserted-nullish-coalescing.md +++ b/packages/eslint-plugin/docs/rules/no-non-null-asserted-nullish-coalescing.md @@ -66,11 +66,3 @@ If you are not using TypeScript 3.7 (or greater), then you will not need to use - [TypeScript 3.7 Release Notes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html) - [Nullish Coalescing Proposal](https://github.com/tc39/proposal-nullish-coalescing) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-non-null-asserted-optional-chain.md b/packages/eslint-plugin/docs/rules/no-non-null-asserted-optional-chain.md index 4772ebc9cca7..c1807f8d7ddb 100644 --- a/packages/eslint-plugin/docs/rules/no-non-null-asserted-optional-chain.md +++ b/packages/eslint-plugin/docs/rules/no-non-null-asserted-optional-chain.md @@ -65,11 +65,3 @@ If you are not using TypeScript 3.7 (or greater), then you will not need to use - [TypeScript 3.7 Release Notes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html) - [Optional Chaining Proposal](https://github.com/tc39/proposal-optional-chaining/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-non-null-assertion.md b/packages/eslint-plugin/docs/rules/no-non-null-assertion.md index 9f84436d61ca..9f2368a9522c 100644 --- a/packages/eslint-plugin/docs/rules/no-non-null-assertion.md +++ b/packages/eslint-plugin/docs/rules/no-non-null-assertion.md @@ -52,11 +52,3 @@ If you don't care about strict null-checking, then you will not need this rule. ## Further Reading - [`no-non-null-assertion`](https://palantir.github.io/tslint/rules/no-non-null-assertion/) in [TSLint](https://palantir.github.io/tslint/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-parameter-properties.md b/packages/eslint-plugin/docs/rules/no-parameter-properties.md index 3f308256efb4..153ea4cb0383 100644 --- a/packages/eslint-plugin/docs/rules/no-parameter-properties.md +++ b/packages/eslint-plugin/docs/rules/no-parameter-properties.md @@ -399,11 +399,3 @@ If you don't care about the using parameter properties in constructors, then you ## Related To - TSLint: [no-parameter-properties](https://palantir.github.io/tslint/rules/no-parameter-properties/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-redeclare.md b/packages/eslint-plugin/docs/rules/no-redeclare.md index 37859e58912c..520229b380c0 100644 --- a/packages/eslint-plugin/docs/rules/no-redeclare.md +++ b/packages/eslint-plugin/docs/rules/no-redeclare.md @@ -84,11 +84,3 @@ const something = 2; Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-redeclare.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-redundant-type-constituents.md b/packages/eslint-plugin/docs/rules/no-redundant-type-constituents.md index 3b96bd19ad19..57a71c2cc2e3 100644 --- a/packages/eslint-plugin/docs/rules/no-redundant-type-constituents.md +++ b/packages/eslint-plugin/docs/rules/no-redundant-type-constituents.md @@ -90,11 +90,3 @@ It also does not provide an auto-fixer just yet. - [Intersection Types](https://www.typescriptlang.org/docs/handbook/2/objects.html#intersection-types) - [Bottom Types](https://en.wikipedia.org/wiki/Bottom_type) - [Top Types](https://en.wikipedia.org/wiki/Top_type) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-require-imports.md b/packages/eslint-plugin/docs/rules/no-require-imports.md index 8344ec726c42..0d7e68bf1af8 100644 --- a/packages/eslint-plugin/docs/rules/no-require-imports.md +++ b/packages/eslint-plugin/docs/rules/no-require-imports.md @@ -51,11 +51,3 @@ If you don't care about TypeScript module syntax, then you will not need this ru ## Related To - TSLint: [no-require-imports](https://palantir.github.io/tslint/rules/no-require-imports/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-restricted-imports.md b/packages/eslint-plugin/docs/rules/no-restricted-imports.md index 3f20d05bb2b6..fcbc0dd3ac43 100644 --- a/packages/eslint-plugin/docs/rules/no-restricted-imports.md +++ b/packages/eslint-plugin/docs/rules/no-restricted-imports.md @@ -68,11 +68,3 @@ export type { Foo } from 'import-foo'; import type baz from 'import-baz'; export type { Baz } from 'import-baz'; ``` - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-shadow.md b/packages/eslint-plugin/docs/rules/no-shadow.md index 4706fabe90e9..5edd068219aa 100644 --- a/packages/eslint-plugin/docs/rules/no-shadow.md +++ b/packages/eslint-plugin/docs/rules/no-shadow.md @@ -91,11 +91,3 @@ type Func = (test: string) => typeof test; Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-shadow.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-this-alias.md b/packages/eslint-plugin/docs/rules/no-this-alias.md index ec76dcf97a69..054a7a04c531 100644 --- a/packages/eslint-plugin/docs/rules/no-this-alias.md +++ b/packages/eslint-plugin/docs/rules/no-this-alias.md @@ -60,11 +60,3 @@ If you need to assign `this` to variables, you shouldn’t use this rule. ## Related To - TSLint: [`no-this-assignment`](https://palantir.github.io/tslint/rules/no-this-assignment/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-throw-literal.md b/packages/eslint-plugin/docs/rules/no-throw-literal.md index ff5f8bb04d16..3ce3d61334c2 100644 --- a/packages/eslint-plugin/docs/rules/no-throw-literal.md +++ b/packages/eslint-plugin/docs/rules/no-throw-literal.md @@ -116,11 +116,3 @@ throw new CustomError(); Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-throw-literal.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-type-alias.md b/packages/eslint-plugin/docs/rules/no-type-alias.md index 734c6de8d3fb..cf76cd21f1f5 100644 --- a/packages/eslint-plugin/docs/rules/no-type-alias.md +++ b/packages/eslint-plugin/docs/rules/no-type-alias.md @@ -596,11 +596,3 @@ callback, etc. that would cause the code to be unreadable or impractical. ## Related To - TSLint: [interface-over-type-literal](https://palantir.github.io/tslint/rules/interface-over-type-literal/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-boolean-literal-compare.md b/packages/eslint-plugin/docs/rules/no-unnecessary-boolean-literal-compare.md index a3f4316d6913..a4e0d8158b6b 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-boolean-literal-compare.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-boolean-literal-compare.md @@ -150,11 +150,3 @@ if (!(someNullCondition ?? true)) { ## Related To - TSLint: [no-boolean-literal-compare](https://palantir.github.io/tslint/rules/no-boolean-literal-compare) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-condition.md b/packages/eslint-plugin/docs/rules/no-unnecessary-condition.md index 992e6d409ea5..9b0f2c1f0f3e 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-condition.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-condition.md @@ -112,11 +112,3 @@ The main downside to using this rule is the need for type information. - ESLint: [no-constant-condition](https://eslint.org/docs/rules/no-constant-condition) - `no-unnecessary-condition` is essentially a stronger version of `no-constant-condition`, but requires type information. - [strict-boolean-expressions](./strict-boolean-expressions.md) - a more opinionated version of `no-unnecessary-condition`. `strict-boolean-expressions` enforces a specific code style, while `no-unnecessary-condition` is about correctness. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-qualifier.md b/packages/eslint-plugin/docs/rules/no-unnecessary-qualifier.md index 36fc50d7fe9c..1a77d8609f53 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-qualifier.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-qualifier.md @@ -96,11 +96,3 @@ If you don't care about having unneeded namespace or enum qualifiers, then you d ## Related To - TSLint: [no-unnecessary-qualifier](https://palantir.github.io/tslint/rules/no-unnecessary-qualifier/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-type-arguments.md b/packages/eslint-plugin/docs/rules/no-unnecessary-type-arguments.md index 6473b8712642..c16b41c8a257 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-type-arguments.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-type-arguments.md @@ -70,11 +70,3 @@ This rule is not configurable. ## Related To - TSLint: [use-default-type-parameter](https://palantir.github.io/tslint/rules/use-default-type-parameter) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-type-assertion.md b/packages/eslint-plugin/docs/rules/no-unnecessary-type-assertion.md index 66e37f70f06c..9c0c99b2616d 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-type-assertion.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-type-assertion.md @@ -77,11 +77,3 @@ If you don't care about having no-op type assertions in your code, then you can ## Related To - TSLint: [`no-unnecessary-type-assertion`](https://palantir.github.io/tslint/rules/no-unnecessary-type-assertion/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unnecessary-type-constraint.md b/packages/eslint-plugin/docs/rules/no-unnecessary-type-constraint.md index e54af4015d18..b2fb9c6b2b95 100644 --- a/packages/eslint-plugin/docs/rules/no-unnecessary-type-constraint.md +++ b/packages/eslint-plugin/docs/rules/no-unnecessary-type-constraint.md @@ -72,11 +72,3 @@ This rule is not configurable. ## When Not To Use It If you don't care about the specific styles of your type constraints, or never use them in the first place, then you will not need this rule. - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unsafe-argument.md b/packages/eslint-plugin/docs/rules/no-unsafe-argument.md index 2ed2f3f423ae..52682fe2408b 100644 --- a/packages/eslint-plugin/docs/rules/no-unsafe-argument.md +++ b/packages/eslint-plugin/docs/rules/no-unsafe-argument.md @@ -88,11 +88,3 @@ This rule is not configurable. - [`no-explicit-any`](./no-explicit-any.md) - TSLint: [`no-unsafe-any`](https://palantir.github.io/tslint/rules/no-unsafe-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unsafe-assignment.md b/packages/eslint-plugin/docs/rules/no-unsafe-assignment.md index 12a934b25dfe..438e8f9a476f 100644 --- a/packages/eslint-plugin/docs/rules/no-unsafe-assignment.md +++ b/packages/eslint-plugin/docs/rules/no-unsafe-assignment.md @@ -91,11 +91,3 @@ This rule is not configurable. - [`no-explicit-any`](./no-explicit-any.md) - TSLint: [`no-unsafe-any`](https://palantir.github.io/tslint/rules/no-unsafe-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unsafe-call.md b/packages/eslint-plugin/docs/rules/no-unsafe-call.md index c883f0ff2776..0b9e7c04ac7e 100644 --- a/packages/eslint-plugin/docs/rules/no-unsafe-call.md +++ b/packages/eslint-plugin/docs/rules/no-unsafe-call.md @@ -65,11 +65,3 @@ This rule is not configurable. - [`no-explicit-any`](./no-explicit-any.md) - TSLint: [`no-unsafe-any`](https://palantir.github.io/tslint/rules/no-unsafe-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unsafe-member-access.md b/packages/eslint-plugin/docs/rules/no-unsafe-member-access.md index da4b46633e5f..87f9c0a50f96 100644 --- a/packages/eslint-plugin/docs/rules/no-unsafe-member-access.md +++ b/packages/eslint-plugin/docs/rules/no-unsafe-member-access.md @@ -71,11 +71,3 @@ This rule is not configurable. - [`no-explicit-any`](./no-explicit-any.md) - TSLint: [`no-unsafe-any`](https://palantir.github.io/tslint/rules/no-unsafe-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unsafe-return.md b/packages/eslint-plugin/docs/rules/no-unsafe-return.md index 933bd5110a0f..b1576a1bb4a0 100644 --- a/packages/eslint-plugin/docs/rules/no-unsafe-return.md +++ b/packages/eslint-plugin/docs/rules/no-unsafe-return.md @@ -108,11 +108,3 @@ This rule is not configurable. - [`no-explicit-any`](./no-explicit-any.md) - TSLint: [`no-unsafe-any`](https://palantir.github.io/tslint/rules/no-unsafe-any/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unused-expressions.md b/packages/eslint-plugin/docs/rules/no-unused-expressions.md index cdd53d2a53d5..45dcf0b1840b 100644 --- a/packages/eslint-plugin/docs/rules/no-unused-expressions.md +++ b/packages/eslint-plugin/docs/rules/no-unused-expressions.md @@ -26,11 +26,3 @@ See [`eslint/no-unused-expressions` options](https://eslint.org/docs/rules/no-un Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-unused-expressions.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-unused-vars.md b/packages/eslint-plugin/docs/rules/no-unused-vars.md index c361b263b0cd..88c97a0febfa 100644 --- a/packages/eslint-plugin/docs/rules/no-unused-vars.md +++ b/packages/eslint-plugin/docs/rules/no-unused-vars.md @@ -26,11 +26,3 @@ See [`eslint/no-unused-vars` options](https://eslint.org/docs/rules/no-unused-va Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-unused-vars.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-use-before-define.md b/packages/eslint-plugin/docs/rules/no-use-before-define.md index cdc1e0373916..c5f545545f16 100644 --- a/packages/eslint-plugin/docs/rules/no-use-before-define.md +++ b/packages/eslint-plugin/docs/rules/no-use-before-define.md @@ -112,11 +112,3 @@ See [`eslint/no-use-before-define` options](https://eslint.org/docs/rules/no-use Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/no-use-before-define.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-useless-constructor.md b/packages/eslint-plugin/docs/rules/no-useless-constructor.md index 511a81bfc491..c50a15c511ae 100644 --- a/packages/eslint-plugin/docs/rules/no-useless-constructor.md +++ b/packages/eslint-plugin/docs/rules/no-useless-constructor.md @@ -35,11 +35,3 @@ Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/ This lint rule will report on constructors whose sole purpose is to change visibility of a parent constructor. See [discussion on this rule's lack of type information](https://github.com/typescript-eslint/typescript-eslint/issues/3820#issuecomment-917821240) for context. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-useless-empty-export.md b/packages/eslint-plugin/docs/rules/no-useless-empty-export.md index 0042e30e97d3..d1973b52e2cc 100644 --- a/packages/eslint-plugin/docs/rules/no-useless-empty-export.md +++ b/packages/eslint-plugin/docs/rules/no-useless-empty-export.md @@ -50,11 +50,3 @@ import 'some-other-module'; ``` This rule is not configurable. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/no-var-requires.md b/packages/eslint-plugin/docs/rules/no-var-requires.md index 819dab59d839..be17c6751e9f 100644 --- a/packages/eslint-plugin/docs/rules/no-var-requires.md +++ b/packages/eslint-plugin/docs/rules/no-var-requires.md @@ -46,11 +46,3 @@ If you don't care about TypeScript module syntax, then you will not need this ru ## Related To - TSLint: [no-var-requires](https://palantir.github.io/tslint/rules/no-var-requires/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/non-nullable-type-assertion-style.md b/packages/eslint-plugin/docs/rules/non-nullable-type-assertion-style.md index bebf23f28133..e6caa5c8b031 100644 --- a/packages/eslint-plugin/docs/rules/non-nullable-type-assertion-style.md +++ b/packages/eslint-plugin/docs/rules/non-nullable-type-assertion-style.md @@ -44,11 +44,3 @@ This rule is not configurable. ## When Not To Use It If you don't mind having unnecessarily verbose type casts, you can avoid this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/object-curly-spacing.md b/packages/eslint-plugin/docs/rules/object-curly-spacing.md index c90baead9ca7..515ff5ab231b 100644 --- a/packages/eslint-plugin/docs/rules/object-curly-spacing.md +++ b/packages/eslint-plugin/docs/rules/object-curly-spacing.md @@ -26,11 +26,3 @@ See [`eslint/object-curly-spacing` options](https://eslint.org/docs/rules/object Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/object-curly-spacing.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/padding-line-between-statements.md b/packages/eslint-plugin/docs/rules/padding-line-between-statements.md index d8c5a29ca724..963e39a11f8b 100644 --- a/packages/eslint-plugin/docs/rules/padding-line-between-statements.md +++ b/packages/eslint-plugin/docs/rules/padding-line-between-statements.md @@ -54,11 +54,3 @@ In addition to options provided by ESLint, `interface` and `type` can be used as Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/padding-line-between-statements.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/parameter-properties.md b/packages/eslint-plugin/docs/rules/parameter-properties.md index 773216e6cd07..4135a38cdae0 100644 --- a/packages/eslint-plugin/docs/rules/parameter-properties.md +++ b/packages/eslint-plugin/docs/rules/parameter-properties.md @@ -486,11 +486,3 @@ If you don't care about the using parameter properties in constructors, then you ## Related To - TSLint: [no-parameter-properties](https://palantir.github.io/tslint/rules/no-parameter-properties/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-as-const.md b/packages/eslint-plugin/docs/rules/prefer-as-const.md index 736f8734ec1a..a0b7302d34f8 100644 --- a/packages/eslint-plugin/docs/rules/prefer-as-const.md +++ b/packages/eslint-plugin/docs/rules/prefer-as-const.md @@ -47,11 +47,3 @@ This rule is not configurable. ## When Not To Use It If you are using TypeScript < 3.4 - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-enum-initializers.md b/packages/eslint-plugin/docs/rules/prefer-enum-initializers.md index 014349bc0d92..33ff21fc0f64 100644 --- a/packages/eslint-plugin/docs/rules/prefer-enum-initializers.md +++ b/packages/eslint-plugin/docs/rules/prefer-enum-initializers.md @@ -87,11 +87,3 @@ This rule is not configurable. ## When Not To Use It If you don't care about `enum`s having implicit values you can safely disable this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-for-of.md b/packages/eslint-plugin/docs/rules/prefer-for-of.md index 78fc4543e12d..3704a58438c7 100644 --- a/packages/eslint-plugin/docs/rules/prefer-for-of.md +++ b/packages/eslint-plugin/docs/rules/prefer-for-of.md @@ -58,11 +58,3 @@ If you transpile for browsers that do not support for-of loops, you may wish to ## Related To - TSLint: ['prefer-for-of'](https://palantir.github.io/tslint/rules/prefer-for-of/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-function-type.md b/packages/eslint-plugin/docs/rules/prefer-function-type.md index b64b07718bb6..504ffe97dc57 100644 --- a/packages/eslint-plugin/docs/rules/prefer-function-type.md +++ b/packages/eslint-plugin/docs/rules/prefer-function-type.md @@ -98,11 +98,3 @@ If you specifically want to use an interface or type literal with a single call ## Further Reading - TSLint: [`callable-types`](https://palantir.github.io/tslint/rules/callable-types/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-includes.md b/packages/eslint-plugin/docs/rules/prefer-includes.md index 3c3bd628aa73..35b1d8d2c2fa 100644 --- a/packages/eslint-plugin/docs/rules/prefer-includes.md +++ b/packages/eslint-plugin/docs/rules/prefer-includes.md @@ -86,11 +86,3 @@ This rule is not configurable. ## When Not To Use It If you don't want to suggest `includes`, you can safely turn this rule off. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-literal-enum-member.md b/packages/eslint-plugin/docs/rules/prefer-literal-enum-member.md index 65f0d8dc1a62..a12bb19938e3 100644 --- a/packages/eslint-plugin/docs/rules/prefer-literal-enum-member.md +++ b/packages/eslint-plugin/docs/rules/prefer-literal-enum-member.md @@ -96,11 +96,3 @@ enum Foo { ## When Not To Use It If you want use anything other than simple literals as an enum value. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-namespace-keyword.md b/packages/eslint-plugin/docs/rules/prefer-namespace-keyword.md index b6ec63fd81e6..7dc26e5662ce 100644 --- a/packages/eslint-plugin/docs/rules/prefer-namespace-keyword.md +++ b/packages/eslint-plugin/docs/rules/prefer-namespace-keyword.md @@ -35,11 +35,3 @@ This rule is not configurable. ## Related To - TSLint: [no-internal-module](https://palantir.github.io/tslint/rules/no-internal-module/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-nullish-coalescing.md b/packages/eslint-plugin/docs/rules/prefer-nullish-coalescing.md index 54c08e1d464b..dec889f13e51 100644 --- a/packages/eslint-plugin/docs/rules/prefer-nullish-coalescing.md +++ b/packages/eslint-plugin/docs/rules/prefer-nullish-coalescing.md @@ -141,11 +141,3 @@ If you are not using TypeScript 3.7 (or greater), then you will not be able to u - [TypeScript 3.7 Release Notes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html) - [Nullish Coalescing Operator Proposal](https://github.com/tc39/proposal-nullish-coalescing/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-optional-chain.md b/packages/eslint-plugin/docs/rules/prefer-optional-chain.md index df77f58a0e5c..289d4ad93509 100644 --- a/packages/eslint-plugin/docs/rules/prefer-optional-chain.md +++ b/packages/eslint-plugin/docs/rules/prefer-optional-chain.md @@ -106,11 +106,3 @@ If you are not using TypeScript 3.7 (or greater), then you will not be able to u - [TypeScript 3.7 Release Notes](https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html) - [Optional Chaining Proposal](https://github.com/tc39/proposal-optional-chaining/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-readonly-parameter-types.md b/packages/eslint-plugin/docs/rules/prefer-readonly-parameter-types.md index 82ba37fa6663..de098de59b7e 100644 --- a/packages/eslint-plugin/docs/rules/prefer-readonly-parameter-types.md +++ b/packages/eslint-plugin/docs/rules/prefer-readonly-parameter-types.md @@ -277,11 +277,3 @@ type MyType = { }; function foo(arg: MyType) {} ``` - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-readonly.md b/packages/eslint-plugin/docs/rules/prefer-readonly.md index 7d145515e128..66b83d1b4556 100644 --- a/packages/eslint-plugin/docs/rules/prefer-readonly.md +++ b/packages/eslint-plugin/docs/rules/prefer-readonly.md @@ -89,11 +89,3 @@ class Container { ## Related To - TSLint: ['prefer-readonly'](https://palantir.github.io/tslint/rules/prefer-readonly) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-reduce-type-parameter.md b/packages/eslint-plugin/docs/rules/prefer-reduce-type-parameter.md index 49ef8d4330da..ada54ec2b00f 100644 --- a/packages/eslint-plugin/docs/rules/prefer-reduce-type-parameter.md +++ b/packages/eslint-plugin/docs/rules/prefer-reduce-type-parameter.md @@ -67,11 +67,3 @@ This rule is not configurable. ## When Not To Use It If you don't want to use typechecking in your linting, you can't use this rule. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-regexp-exec.md b/packages/eslint-plugin/docs/rules/prefer-regexp-exec.md index d4a415752f37..925b4cc24f5c 100644 --- a/packages/eslint-plugin/docs/rules/prefer-regexp-exec.md +++ b/packages/eslint-plugin/docs/rules/prefer-regexp-exec.md @@ -58,11 +58,3 @@ This rule is not configurable. ## When Not To Use It If you prefer consistent use of `String#match` for both, with `g` flag and without it, you can turn this rule off. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-return-this-type.md b/packages/eslint-plugin/docs/rules/prefer-return-this-type.md index d6648458767b..2ccf2c858a1b 100644 --- a/packages/eslint-plugin/docs/rules/prefer-return-this-type.md +++ b/packages/eslint-plugin/docs/rules/prefer-return-this-type.md @@ -109,11 +109,3 @@ This rule is not configurable. ## When Not To Use It If you don't use method chaining or explicit return values, you can safely turn this rule off. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-string-starts-ends-with.md b/packages/eslint-plugin/docs/rules/prefer-string-starts-ends-with.md index 0ae2553c09d4..895fb9e72afb 100644 --- a/packages/eslint-plugin/docs/rules/prefer-string-starts-ends-with.md +++ b/packages/eslint-plugin/docs/rules/prefer-string-starts-ends-with.md @@ -61,11 +61,3 @@ This rule is not configurable. ## When Not To Use It If you don't mind that style, you can turn this rule off safely. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/prefer-ts-expect-error.md b/packages/eslint-plugin/docs/rules/prefer-ts-expect-error.md index 06811604ce22..af1e3214dbfc 100644 --- a/packages/eslint-plugin/docs/rules/prefer-ts-expect-error.md +++ b/packages/eslint-plugin/docs/rules/prefer-ts-expect-error.md @@ -82,11 +82,3 @@ If you are **NOT** using TypeScript 3.9 (or greater), then you will not be able ## Further Reading - [Original Implementing PR](https://github.com/microsoft/TypeScript/pull/36014) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/promise-function-async.md b/packages/eslint-plugin/docs/rules/promise-function-async.md index 2191277b83b2..cb12d3895157 100644 --- a/packages/eslint-plugin/docs/rules/promise-function-async.md +++ b/packages/eslint-plugin/docs/rules/promise-function-async.md @@ -70,11 +70,3 @@ In addition, each of the following properties may be provided, and default to `t ## Related To - TSLint: [promise-function-async](https://palantir.github.io/tslint/rules/promise-function-async) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/quotes.md b/packages/eslint-plugin/docs/rules/quotes.md index daaf3e509bc0..deaf88e5547f 100644 --- a/packages/eslint-plugin/docs/rules/quotes.md +++ b/packages/eslint-plugin/docs/rules/quotes.md @@ -26,11 +26,3 @@ See [`eslint/quotes` options](https://eslint.org/docs/rules/quotes#options). Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/quotes.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/require-array-sort-compare.md b/packages/eslint-plugin/docs/rules/require-array-sort-compare.md index 74d1a8dc4fbf..23694f06d6ae 100644 --- a/packages/eslint-plugin/docs/rules/require-array-sort-compare.md +++ b/packages/eslint-plugin/docs/rules/require-array-sort-compare.md @@ -97,11 +97,3 @@ const three = '3'; ## When Not To Use It If you understand the language specification enough, you can turn this rule off safely. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/require-await.md b/packages/eslint-plugin/docs/rules/require-await.md index c75a40803cef..b8698928eaf0 100644 --- a/packages/eslint-plugin/docs/rules/require-await.md +++ b/packages/eslint-plugin/docs/rules/require-await.md @@ -36,11 +36,3 @@ See [`eslint/require-await` options](https://eslint.org/docs/rules/require-await Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/require-await.md) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/restrict-plus-operands.md b/packages/eslint-plugin/docs/rules/restrict-plus-operands.md index d4741186e4ce..71de181b6dce 100644 --- a/packages/eslint-plugin/docs/rules/restrict-plus-operands.md +++ b/packages/eslint-plugin/docs/rules/restrict-plus-operands.md @@ -104,11 +104,3 @@ var fn = (a: any, b: number) => a + b; ## Related To - TSLint: [restrict-plus-operands](https://palantir.github.io/tslint/rules/restrict-plus-operands/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/restrict-template-expressions.md b/packages/eslint-plugin/docs/rules/restrict-template-expressions.md index 5593090a482c..59c51c417bd0 100644 --- a/packages/eslint-plugin/docs/rules/restrict-template-expressions.md +++ b/packages/eslint-plugin/docs/rules/restrict-template-expressions.md @@ -108,11 +108,3 @@ const msg1 = `arg = ${arg}`; const arg = /foo/; const msg1 = `arg = ${arg}`; ``` - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/return-await.md b/packages/eslint-plugin/docs/rules/return-await.md index 8d4e97298da5..20e99158dffa 100644 --- a/packages/eslint-plugin/docs/rules/return-await.md +++ b/packages/eslint-plugin/docs/rules/return-await.md @@ -220,11 +220,3 @@ async function validNever3() { return 'value'; } ``` - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/semi.md b/packages/eslint-plugin/docs/rules/semi.md index 7a9e125fa2b1..d74151f0e7eb 100644 --- a/packages/eslint-plugin/docs/rules/semi.md +++ b/packages/eslint-plugin/docs/rules/semi.md @@ -30,11 +30,3 @@ See [`eslint/semi` options](https://eslint.org/docs/rules/semi#options). Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/semi.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/sort-type-union-intersection-members.md b/packages/eslint-plugin/docs/rules/sort-type-union-intersection-members.md index 49639338141d..53000a3cab4e 100644 --- a/packages/eslint-plugin/docs/rules/sort-type-union-intersection-members.md +++ b/packages/eslint-plugin/docs/rules/sort-type-union-intersection-members.md @@ -151,11 +151,3 @@ The ordering of groups is determined by this option. - `tuple` - Tuple types (`[A, B, C]`) - `union` - Union types (`A | B`) - `nullish` - `null` and `undefined` - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/space-before-blocks.md b/packages/eslint-plugin/docs/rules/space-before-blocks.md index dce543bbf212..5ff10537795f 100644 --- a/packages/eslint-plugin/docs/rules/space-before-blocks.md +++ b/packages/eslint-plugin/docs/rules/space-before-blocks.md @@ -52,11 +52,3 @@ See [`eslint/space-before-blocks` options](https://eslint.org/docs/rules/space-b Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/master/docs/rules/space-before-blocks.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/space-before-function-paren.md b/packages/eslint-plugin/docs/rules/space-before-function-paren.md index 88f6d5d4c998..4664dd4c6a51 100644 --- a/packages/eslint-plugin/docs/rules/space-before-function-paren.md +++ b/packages/eslint-plugin/docs/rules/space-before-function-paren.md @@ -26,11 +26,3 @@ See [`eslint/space-before-function-paren` options](https://eslint.org/docs/rules Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/space-before-function-paren.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/space-infix-ops.md b/packages/eslint-plugin/docs/rules/space-infix-ops.md index 21dd58c312dc..ced780013136 100644 --- a/packages/eslint-plugin/docs/rules/space-infix-ops.md +++ b/packages/eslint-plugin/docs/rules/space-infix-ops.md @@ -30,11 +30,3 @@ See [`eslint/space-infix-ops` options](https://eslint.org/docs/rules/space-infix Taken with ❤️ [from ESLint core](https://github.com/eslint/eslint/blob/main/docs/rules/space-infix-ops.md) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/strict-boolean-expressions.md b/packages/eslint-plugin/docs/rules/strict-boolean-expressions.md index f993881c8c22..4389f08dd809 100644 --- a/packages/eslint-plugin/docs/rules/strict-boolean-expressions.md +++ b/packages/eslint-plugin/docs/rules/strict-boolean-expressions.md @@ -197,11 +197,3 @@ This rule provides following fixes and suggestions for particular types in boole - TSLint: [strict-boolean-expressions](https://palantir.github.io/tslint/rules/strict-boolean-expressions) - [no-unnecessary-condition](./no-unnecessary-condition.md) - Similar rule which reports always-truthy and always-falsy values in conditions - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.md b/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.md index df6fc1f72bc4..a594c7f3d7bb 100644 --- a/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.md +++ b/packages/eslint-plugin/docs/rules/switch-exhaustiveness-check.md @@ -122,11 +122,3 @@ This rule is not configurable. ## When Not To Use It If program doesn't have union types with many parts. Downside of this rule is the need for type information, so it's slower than regular rules. - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/triple-slash-reference.md b/packages/eslint-plugin/docs/rules/triple-slash-reference.md index d15d1cc5e129..9fa1c02c02f1 100644 --- a/packages/eslint-plugin/docs/rules/triple-slash-reference.md +++ b/packages/eslint-plugin/docs/rules/triple-slash-reference.md @@ -72,11 +72,3 @@ If you want to use all flavors of triple slash reference directives. - TSLint: [no-reference](http://palantir.github.io/tslint/rules/no-reference/) - TSLint: [no-reference-import](https://palantir.github.io/tslint/rules/no-reference-import/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/type-annotation-spacing.md b/packages/eslint-plugin/docs/rules/type-annotation-spacing.md index 903e9faf8194..0d33f78a3df2 100644 --- a/packages/eslint-plugin/docs/rules/type-annotation-spacing.md +++ b/packages/eslint-plugin/docs/rules/type-annotation-spacing.md @@ -311,11 +311,3 @@ If you don't want to enforce spacing for your type annotations, you can safely t ## Related To - TSLint: [`typedef-whitespace`](https://palantir.github.io/tslint/rules/typedef-whitespace/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [x] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/typedef.md b/packages/eslint-plugin/docs/rules/typedef.md index cbe3bcd3cb07..5daa78987817 100644 --- a/packages/eslint-plugin/docs/rules/typedef.md +++ b/packages/eslint-plugin/docs/rules/typedef.md @@ -340,11 +340,3 @@ In general, if you do not consider the cost of writing unnecessary type annotati ## Related To - TSLint: [`typedef`](https://palantir.github.io/tslint/rules/typedef) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [ ] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/unbound-method.md b/packages/eslint-plugin/docs/rules/unbound-method.md index cef79e426017..58a98c79051c 100644 --- a/packages/eslint-plugin/docs/rules/unbound-method.md +++ b/packages/eslint-plugin/docs/rules/unbound-method.md @@ -118,11 +118,3 @@ If you're wanting to use `toBeCalled` and similar matches in `jest` tests, you c ## Related To - TSLint: [no-unbound-method](https://palantir.github.io/tslint/rules/no-unbound-method/) - -## Attributes - -- Configs: - - [x] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [x] 💭 Requires type information diff --git a/packages/eslint-plugin/docs/rules/unified-signatures.md b/packages/eslint-plugin/docs/rules/unified-signatures.md index b308aff9d635..ff0a6f7008d5 100644 --- a/packages/eslint-plugin/docs/rules/unified-signatures.md +++ b/packages/eslint-plugin/docs/rules/unified-signatures.md @@ -79,11 +79,3 @@ function f(...a: string[]): void; ## Related To - TSLint: [`unified-signatures`](https://palantir.github.io/tslint/rules/unified-signatures/) - -## Attributes - -- Configs: - - [ ] ✅ Recommended - - [x] 🔒 Strict -- [ ] 🔧 Fixable -- [ ] 💭 Requires type information diff --git a/packages/eslint-plugin/tests/docs.test.ts b/packages/eslint-plugin/tests/docs.test.ts index ca7cc5fbd8f4..fb52ea42cbfb 100644 --- a/packages/eslint-plugin/tests/docs.test.ts +++ b/packages/eslint-plugin/tests/docs.test.ts @@ -1,4 +1,3 @@ -import { TSESLint } from '@typescript-eslint/utils'; import fs from 'fs'; import { JSONSchema4 } from 'json-schema'; import path from 'path'; @@ -169,38 +168,6 @@ describe('Validating rule docs', () => { text: 'This rule is not configurable.', }); }); - - it(`Attributes in ${ruleName}.md must match the metadata`, () => { - const tokens = parseMarkdownFile(filePath); - - // Verify attributes header exists - const attributesHeaderIndex = tokens.findIndex( - token => tokenIs(token, 'heading') && token.text === 'Attributes', - ); - expect(attributesHeaderIndex).toBeGreaterThan(-1); - - // Verify attributes content... - const attributesList = tokenAs( - tokens[attributesHeaderIndex + 1], - 'list', - ); - // ...starting with configs - const configs = attributesList.items[0]; - expect(configs.text).toMatch(/Configs:\n/); - const configsList = tokenAs(configs.tokens[1], 'list'); - const recommended = configsList.items[0]; - expect(shouldBeRecommended(rule.meta.docs)).toBe(recommended.checked); - const strict = configsList.items[1]; - expect(shouldBeStrict(rule.meta.docs)).toBe(strict.checked); - - // Verify other attributes - const fixable = attributesList.items[1]; - expect(rule.meta.fixable !== undefined).toBe(fixable.checked); - const requiresTypeChecking = attributesList.items[2]; - expect(rule.meta.docs?.requiresTypeChecking === true).toBe( - requiresTypeChecking.checked, - ); - }); }); } }); @@ -316,13 +283,3 @@ describe('Validating README.md', () => { }); } }); - -function shouldBeRecommended( - docs: TSESLint.RuleMetaDataDocs | undefined, -): boolean { - return docs?.recommended !== false && docs?.recommended !== 'strict'; -} - -function shouldBeStrict(docs: TSESLint.RuleMetaDataDocs | undefined): boolean { - return docs?.recommended !== false; -} diff --git a/packages/website/docusaurus.config.js b/packages/website/docusaurus.config.js index a06a8e0367dc..e2d6411e7931 100644 --- a/packages/website/docusaurus.config.js +++ b/packages/website/docusaurus.config.js @@ -1,193 +1,10 @@ -// @ts-check -// Note: type annotations allow type checking and IDEs autocompletion +'use strict'; -const remarkPlugins = [ - [require('@docusaurus/remark-plugin-npm2yarn'), { sync: true }], -]; +require('ts-node').register({ + scope: true, + scopeDir: __dirname, + swc: true, + transpileOnly: true, +}); -const beforeDefaultRemarkPlugins = [[require('remark-docusaurus-tabs'), {}]]; - -const githubUrl = 'https://github.com/typescript-eslint/typescript-eslint'; - -/** @type {import('@docusaurus/types').Config} */ -const config = { - title: 'TypeScript ESLint', - tagline: 'Tooling which enables ESLint to support TypeScript', - url: 'https://typescript-eslint.io', - baseUrl: '/', - onBrokenLinks: 'throw', - onBrokenMarkdownLinks: 'warn', // If Markdown link resolution fails, it will result in a broken link anyways - favicon: 'img/favicon.ico', - organizationName: 'typescript-eslint', - projectName: 'typescript-eslint', - clientModules: [require.resolve('./src/clientModules.js')], - presets: [ - [ - 'classic', - /** @type {import('@docusaurus/preset-classic').Options} */ - ({ - docs: { - id: 'rules-docs', - path: '../eslint-plugin/docs/rules', - sidebarPath: require.resolve('./sidebars/sidebar.rules.js'), - routeBasePath: 'rules', - editUrl: `${githubUrl}/edit/main/packages/website/`, - beforeDefaultRemarkPlugins, - remarkPlugins, - exclude: ['TEMPLATE.md'], - breadcrumbs: false, - }, - // TODO enable this - blog: false, - pages: { - beforeDefaultRemarkPlugins, - remarkPlugins, - }, - theme: { - customCss: require.resolve('./src/css/custom.css'), - }, - }), - ], - ], - plugins: [ - require.resolve('./webpack.plugin'), - [ - '@docusaurus/plugin-content-docs', - /** @type {import('@docusaurus/plugin-content-docs').Options} */ - ({ - id: 'base-docs', - path: '../../docs', - routeBasePath: 'docs', - sidebarPath: require.resolve('./sidebars/sidebar.base.js'), - editUrl: `${githubUrl}/edit/main/packages/website/`, - beforeDefaultRemarkPlugins, - remarkPlugins, - breadcrumbs: false, - }), - ], - ], - themeConfig: - /** @type {import('@docusaurus/theme-common').UserThemeConfig} */ - ({ - algolia: { - appId: 'BH4D9OD16A', - apiKey: '1ad6b47d4e742c4c0653877b5511c602', - indexName: 'typescript-eslint', - }, - metadata: [ - { name: 'msapplication-TileColor', content: '#443fd4' }, - { name: 'theme-color', content: '#443fd4' }, - ], - navbar: { - title: 'TypeScript ESLint', - // hideOnScroll: true, - logo: { - alt: 'TypeScript ESLint logo', - height: '32px', - src: 'img/logo.svg', - width: '32px', - }, - // style: 'primary', - items: [ - { - to: 'docs/', - activeBasePath: 'docs', - label: 'Getting started', - position: 'left', - }, - { - to: 'rules/', - activeBasePath: 'rules', - label: 'Rules', - position: 'left', - }, - { - to: 'play', - activeBasePath: 'play', - position: 'right', - label: 'Playground', - }, - { - href: githubUrl, - position: 'right', - className: 'header-github-link', - 'aria-label': 'GitHub repository', - }, - ], - }, - footer: { - logo: { - alt: 'Deploys by Netlify', - src: 'https://www.netlify.com/img/global/badges/netlify-dark.svg', - href: 'https://www.netlify.com', - }, - links: [ - { - title: 'Community', - items: [ - { - label: 'Stack Overflow', - href: 'https://stackoverflow.com/questions/tagged/typescript-eslint', - }, - { - label: 'Twitter', - href: 'https://twitter.com/tseslint', - }, - ], - }, - { - title: 'More', - items: [ - { - label: 'GitHub', - href: 'https://github.com/typescript-eslint/typescript-eslint', - }, - { - label: 'Report issue', - href: 'https://github.com/typescript-eslint/typescript-eslint/issues/new/choose', - }, - ], - }, - ], - // style: 'primary', - copyright: `Copyright © ${new Date().getFullYear()} TypeScript ESLint, Inc. Built with Docusaurus.`, - }, - prism: { - theme: { - plain: {}, - styles: [], - }, - additionalLanguages: ['ignore'], - }, - tableOfContents: { - maxHeadingLevel: 4, - minHeadingLevel: 2, - }, - }), - // Misleading API name, but these are just tags - stylesheets: [ - { - rel: 'apple-touch-icon', - sizes: '180x180', - href: '/img/favicon/apple-touch-icon.png', - }, - { - rel: 'icon', - type: 'image/png', - sizes: '32x32', - href: '/img/favicon/favicon-32x32.png', - }, - { - rel: 'icon', - type: 'image/png', - sizes: '16x16', - href: '/img/favicon/favicon-16x16.png', - }, - { - rel: 'manifest', - href: '/img/favicon/site.webmanifest', - }, - ], -}; - -module.exports = config; +module.exports = require('./docusaurusConfig'); diff --git a/packages/website/docusaurusConfig.ts b/packages/website/docusaurusConfig.ts new file mode 100644 index 000000000000..eab99e5d2eb3 --- /dev/null +++ b/packages/website/docusaurusConfig.ts @@ -0,0 +1,192 @@ +import type { MDXPlugin } from '@docusaurus/mdx-loader'; +import type { Options as PluginContentDocsOptions } from '@docusaurus/plugin-content-docs'; +import type { Options as PresetClassicOptions } from '@docusaurus/preset-classic'; +import type { UserThemeConfig as ThemeCommonConfig } from '@docusaurus/theme-common'; +import type { UserThemeConfig as AlgoliaThemeConfig } from '@docusaurus/theme-search-algolia'; +import type { Config } from '@docusaurus/types'; + +import npm2yarnPlugin from '@docusaurus/remark-plugin-npm2yarn'; +import tabsPlugin from 'remark-docusaurus-tabs'; +import { addRuleAttributesList } from './plugins/add-rule-attributes-list'; + +const remarkPlugins: MDXPlugin[] = [[npm2yarnPlugin, { sync: true }]]; + +const beforeDefaultRemarkPlugins: MDXPlugin[] = [[tabsPlugin, {}]]; + +const githubUrl = 'https://github.com/typescript-eslint/typescript-eslint'; + +const presetClassicOptions: PresetClassicOptions = { + docs: { + id: 'rules-docs', + path: '../eslint-plugin/docs/rules', + sidebarPath: require.resolve('./sidebars/sidebar.rules.js'), + routeBasePath: 'rules', + editUrl: `${githubUrl}/edit/main/packages/website/`, + beforeDefaultRemarkPlugins, + remarkPlugins: [...remarkPlugins, [addRuleAttributesList, {}]], + exclude: ['TEMPLATE.md'], + breadcrumbs: false, + }, + // TODO enable this + blog: false, + pages: { + beforeDefaultRemarkPlugins, + remarkPlugins, + }, + theme: { + customCss: require.resolve('./src/css/custom.css'), + }, +}; + +const pluginContentDocsOptions: PluginContentDocsOptions = { + id: 'base-docs', + path: '../../docs', + routeBasePath: 'docs', + sidebarPath: require.resolve('./sidebars/sidebar.base.js'), + editUrl: `${githubUrl}/edit/main/packages/website/`, + beforeDefaultRemarkPlugins, + remarkPlugins, + breadcrumbs: false, +}; + +const themeConfig: ThemeCommonConfig & AlgoliaThemeConfig = { + algolia: { + appId: 'BH4D9OD16A', + apiKey: '1ad6b47d4e742c4c0653877b5511c602', + indexName: 'typescript-eslint', + }, + metadata: [ + { name: 'msapplication-TileColor', content: '#443fd4' }, + { name: 'theme-color', content: '#443fd4' }, + ], + navbar: { + title: 'TypeScript ESLint', + // hideOnScroll: true, + logo: { + alt: 'TypeScript ESLint logo', + height: '32px', + src: 'img/logo.svg', + width: '32px', + }, + // style: 'primary', + items: [ + { + to: 'docs/', + activeBasePath: 'docs', + label: 'Getting started', + position: 'left', + }, + { + to: 'rules/', + activeBasePath: 'rules', + label: 'Rules', + position: 'left', + }, + { + to: 'play', + activeBasePath: 'play', + position: 'right', + label: 'Playground', + }, + { + href: githubUrl, + position: 'right', + className: 'header-github-link', + 'aria-label': 'GitHub repository', + }, + ], + }, + footer: { + logo: { + alt: 'Deploys by Netlify', + src: 'https://www.netlify.com/img/global/badges/netlify-dark.svg', + href: 'https://www.netlify.com', + }, + links: [ + { + title: 'Community', + items: [ + { + label: 'Stack Overflow', + href: 'https://stackoverflow.com/questions/tagged/typescript-eslint', + }, + { + label: 'Twitter', + href: 'https://twitter.com/tseslint', + }, + ], + }, + { + title: 'More', + items: [ + { + label: 'GitHub', + href: 'https://github.com/typescript-eslint/typescript-eslint', + }, + { + label: 'Report issue', + href: 'https://github.com/typescript-eslint/typescript-eslint/issues/new/choose', + }, + ], + }, + ], + // style: 'primary', + copyright: `Copyright © ${new Date().getFullYear()} TypeScript ESLint, Inc. Built with Docusaurus.`, + }, + prism: { + theme: { + plain: {}, + styles: [], + }, + additionalLanguages: ['ignore'], + }, + tableOfContents: { + maxHeadingLevel: 4, + minHeadingLevel: 2, + }, +}; + +const config: Config = { + title: 'TypeScript ESLint', + tagline: 'Tooling which enables ESLint to support TypeScript', + url: 'https://typescript-eslint.io', + baseUrl: '/', + onBrokenLinks: 'throw', + onBrokenMarkdownLinks: 'warn', // If Markdown link resolution fails, it will result in a broken link anyways + favicon: 'img/favicon.ico', + organizationName: 'typescript-eslint', + projectName: 'typescript-eslint', + clientModules: [require.resolve('./src/clientModules.js')], + presets: [['classic', presetClassicOptions]], + plugins: [ + require.resolve('./webpack.plugin'), + ['@docusaurus/plugin-content-docs', pluginContentDocsOptions], + ], + themeConfig, + // Misleading API name, but these are just tags + stylesheets: [ + { + rel: 'apple-touch-icon', + sizes: '180x180', + href: '/img/favicon/apple-touch-icon.png', + }, + { + rel: 'icon', + type: 'image/png', + sizes: '32x32', + href: '/img/favicon/favicon-32x32.png', + }, + { + rel: 'icon', + type: 'image/png', + sizes: '16x16', + href: '/img/favicon/favicon-16x16.png', + }, + { + rel: 'manifest', + href: '/img/favicon/site.webmanifest', + }, + ], +}; + +export = config; diff --git a/packages/website/package.json b/packages/website/package.json index 9ac1937c0891..7f53c0d7f75f 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -33,6 +33,7 @@ }, "devDependencies": { "@docusaurus/module-type-aliases": "^2.0.0-beta.18", + "@typescript-eslint/eslint-plugin": "5.26.0", "@types/react": "^18.0.9", "@types/react-helmet": "^6.1.5", "@types/react-router-dom": "^5.3.3", diff --git a/packages/website/plugins/add-rule-attributes-list.ts b/packages/website/plugins/add-rule-attributes-list.ts new file mode 100644 index 000000000000..381ca2638a6b --- /dev/null +++ b/packages/website/plugins/add-rule-attributes-list.ts @@ -0,0 +1,203 @@ +import type * as mdast from 'mdast'; +import type { Plugin } from 'unified'; + +import * as eslintPlugin from '@typescript-eslint/eslint-plugin'; + +const addRuleAttributesList: Plugin = () => { + return (root, file) => { + if (file.stem == null) { + return; + } + + const rule = eslintPlugin.rules[file.stem]; + if (rule == null) { + return; + } + const config = ((): 'recommended' | 'strict' | null => { + switch (rule.meta.docs?.recommended) { + case 'error': + case 'warn': + return 'recommended'; + + case 'strict': + return 'strict'; + + default: + return null; + } + })(); + const autoFixable = rule.meta.fixable != null; + const suggestionFixable = rule.meta.hasSuggestions === true; + const requiresTypeInfo = rule.meta.docs?.requiresTypeChecking === true; + + const parent = root as mdast.Parent; + /* + This just outputs a list with a heading like: + +## Attributes + +- [ ] Config + - [ ] ✅ Recommended + - [ ] 🔒 Strict +- [ ] Fixable + - [ ] 🔧 Automated Fixer (`--fix`) + - [ ] 🛠 Suggestion Fixer +- [ ] 💭 Requires type information + */ + const heading = Heading({ + depth: 2, + text: 'Attributes', + }); + const ruleAttributes = List({ + children: [ + NestedList({ + checked: config != null, + children: [ + ListItem({ + checked: config === 'recommended', + text: '✅ Recommended', + }), + ListItem({ + checked: config === 'strict' || config === 'recommended', + text: '🔒 Strict', + }), + ], + text: 'Included in configs', + }), + NestedList({ + checked: autoFixable || suggestionFixable, + children: [ + ListItem({ + checked: autoFixable, + text: '🔧 Automated Fixer', + }), + ListItem({ + checked: suggestionFixable, + text: '🛠 Suggestion Fixer', + }), + ], + text: 'Fixable', + }), + ListItem({ + checked: requiresTypeInfo, + text: '💭 Requires type information', + }), + ], + }); + + const h2Idx = parent.children.findIndex( + child => child.type === 'heading' && child.depth === 2, + ); + if (h2Idx != null) { + // insert it just before the first h2 in the doc + // this should be just after the rule's description + parent.children.splice(h2Idx, 0, heading, ruleAttributes); + } else { + // failing that, add it to the end + parent.children.push(heading, ruleAttributes); + } + }; +}; + +function Heading({ + depth, + text, + id = text.toLowerCase(), +}: { + depth: mdast.Heading['depth']; + id?: string; + text: string; +}): mdast.Heading { + return { + type: 'heading', + depth, + children: [ + { + type: 'text', + value: text, + }, + ], + data: { + hProperties: { + id, + }, + id, + }, + }; +} + +function Paragraph({ text }: { text: string }): mdast.Paragraph { + return { + type: 'paragraph', + children: [ + { + type: 'text', + value: text, + }, + ], + }; +} + +function ListItem({ + checked, + text, +}: { + checked: boolean; + text: string; +}): mdast.ListItem { + return { + type: 'listItem', + spread: false, + checked: checked, + children: [ + { + type: 'paragraph', + children: [ + { + type: 'text', + value: text, + }, + ], + }, + ], + }; +} + +function NestedList({ + children, + checked, + text, +}: { + children: mdast.ListItem[]; + checked: boolean; + text: string; +}): mdast.ListItem { + return { + type: 'listItem', + spread: false, + checked: checked, + children: [ + Paragraph({ + text, + }), + List({ + children, + }), + ], + data: { + className: 'test', + }, + }; +} + +function List({ children }: { children: mdast.ListItem[] }): mdast.List { + return { + type: 'list', + ordered: false, + start: null, + spread: false, + children, + }; +} + +export { addRuleAttributesList }; diff --git a/packages/website/src/css/custom.css b/packages/website/src/css/custom.css index b1e23a6dcd33..2324486fc7e5 100644 --- a/packages/website/src/css/custom.css +++ b/packages/website/src/css/custom.css @@ -108,3 +108,8 @@ h6 { .myLineDecoration { background-color: var(--code-line-decoration); } + +/* indent the nested checklist for the rule doc attributes */ +ul.contains-task-list > li > ul.contains-task-list { + padding-left: 24px; +} diff --git a/packages/website/tsconfig.json b/packages/website/tsconfig.json index 3488d04f2e95..2dd71ec3f252 100644 --- a/packages/website/tsconfig.json +++ b/packages/website/tsconfig.json @@ -16,5 +16,5 @@ }, "types": ["@docusaurus/module-type-aliases", "@docusaurus/theme-classic"] }, - "include": ["src/"] + "include": ["src/", "plugins/", "typings", "./docusaurusConfig.ts"] } diff --git a/packages/website/typings/remark-docusaurus-tabs.d.ts b/packages/website/typings/remark-docusaurus-tabs.d.ts new file mode 100644 index 000000000000..9dab9651dd63 --- /dev/null +++ b/packages/website/typings/remark-docusaurus-tabs.d.ts @@ -0,0 +1,5 @@ +declare module 'remark-docusaurus-tabs' { + import type { Plugin } from 'unified'; + const plugin: Plugin; + export = plugin; +} From 8b5862d981f3551d6970924daf0da6d8fd703299 Mon Sep 17 00:00:00 2001 From: Brad Zacher Date: Mon, 30 May 2022 11:40:58 -0700 Subject: [PATCH 2/2] fix merge --- packages/website/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/website/package.json b/packages/website/package.json index 6c2be083e120..2eaf1c0d1c92 100644 --- a/packages/website/package.json +++ b/packages/website/package.json @@ -33,6 +33,7 @@ }, "devDependencies": { "@docusaurus/module-type-aliases": "^2.0.0-beta.21", + "@typescript-eslint/eslint-plugin": "5.27.0", "@types/react": "^18.0.9", "@types/react-helmet": "^6.1.5", "@types/react-router-dom": "^5.3.3",