Skip to content

Commit

Permalink
docs: mark allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing opt…
Browse files Browse the repository at this point in the history
…ions as deprecated (#9914)
  • Loading branch information
JoshuaKGoldberg authored Sep 8, 2024
1 parent dc549b8 commit 04d1bd0
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ do {} while (true);

### `allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing`

:::danger Deprecated
This option will be removed in the next major version of typescript-eslint.
:::

If this is set to `false`, then the rule will error on every file whose `tsconfig.json` does _not_ have the `strictNullChecks` compiler option (or `strict`) set to `true`.

Without `strictNullChecks`, TypeScript essentially erases `undefined` and `null` from the types. This means when this rule inspects the types from a variable, **it will not be able to tell that the variable might be `null` or `undefined`**, which essentially makes this rule useless.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,11 @@ Also, if you would like to ignore all primitives types, you can set `ignorePrimi

### `allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing`

Unless this is set to `true`, the rule will error on every file whose `tsconfig.json` does _not_ have the `strictNullChecks` compiler option (or `strict`) set to `true`.
:::danger Deprecated

> This option will be removed in the next major version of typescript-eslint.
> :::
> Unless this is set to `true`, the rule will error on every file whose `tsconfig.json` does _not_ have the `strictNullChecks` compiler option (or `strict`) set to `true`.
Without `strictNullChecks`, TypeScript essentially erases `undefined` and `null` from the types. This means when this rule inspects the types from a variable, **it will not be able to tell that the variable might be `null` or `undefined`**, which essentially makes this rule useless.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,11 @@ Set this to `true` at your own risk.

### `allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing`

If this is set to `false`, then the rule will error on every file whose `tsconfig.json` does _not_ have the `strictNullChecks` compiler option (or `strict`) set to `true`.
:::danger Deprecated

> This option will be removed in the next major version of typescript-eslint.
> :::
> If this is set to `false`, then the rule will error on every file whose `tsconfig.json` does _not_ have the `strictNullChecks` compiler option (or `strict`) set to `true`.
Without `strictNullChecks`, TypeScript essentially erases `undefined` and `null` from the types. This means when this rule inspects the types from a variable, **it will not be able to tell that the variable might be `null` or `undefined`**, which essentially makes this rule a lot less useful.

Expand Down

0 comments on commit 04d1bd0

Please sign in to comment.