Open
Description
The Boolean part of this rule and the auto fix break my code, because they don't work well with typescript.
I write this:
const testArray = ['test', null];
const output = testArray.filter((value): value is string => Boolean(value));
and it converts it to this:
const testArray = ['test', null];
const output = testArray.filter(Boolean);
This is not the same. The type of output is Array<string>
in my code and Array<string | null>
in the 'autofixed' code.
Metadata
Metadata
Assignees
Labels
No labels