TS2578
Unused '@ts-expect-error' directive.
Broken Code β
// @ts-expect-error
const age = 42;This error occurs because the @ts-expect-error directive is used, but there is no actual TypeScript error on the next line. The directive should only be used when an error is expected and unavoidable.
Fixed Code βοΈ
If there is no error, you donβt need the directive:
const age = 42;