[no-non-null-asserted-optional-chain] support 3.9's new interaction between optional chains and non-null assertions #1976
Labels
enhancement
New feature or request
has pr
there is a PR raised to close this
package: eslint-plugin
Issues related to @typescript-eslint/eslint-plugin
From: https://devblogs.microsoft.com/typescript/announcing-typescript-3-9-beta/#breaking-changes
@typescript-eslint/no-non-null-asserted-optional-chain
made sense in that case but TS 3.9 will change the behavior to this:So
foo?.bar!.baz
becomes perfectly reasonable to catch an undefinedfoo
but ignore an undefinedfoo.bar
Versions
@typescript-eslint/eslint-plugin
2.27.0
@typescript-eslint/parser
2.27.0
TypeScript
3.9
(future)ESLint
6.8.0
node
12.15
npm
6.13.6
The text was updated successfully, but these errors were encountered: