Closed danielnixon closed 4 years ago
const foo = someAnyValue as unknown;
as unknown should be allowed (even in strict mode). Consider an any (or some other bad type) from a third party library that you want to treat (safely) as unknown.
as unknown
any
as unknown is flagged as untyped (when in strict mode).
fixed in v2.8.2
LGTM, thanks @plantain-00
Version(if relevant): 2.8.1
Environment(if relevant):
Code(if relevant):
Expected:
as unknown
should be allowed (even in strict mode). Consider anany
(or some other bad type) from a third party library that you want to treat (safely) as unknown.Actual:
as unknown
is flagged as untyped (when in strict mode).