Open russelldavis opened 8 months ago
Because type predicates also narrow in the false case, when setHas or arrayIncludes return false, you can end up with incorrect types. More details and examples at https://github.com/total-typescript/ts-reset/pull/125#issuecomment-1926133512
setHas
arrayIncludes
cc @tychenjiajun @younho9
Edited to add that arrayIncludes is unsafe for the same reason.
Because type predicates also narrow in the false case, when
setHas
orarrayIncludes
return false, you can end up with incorrect types. More details and examples at https://github.com/total-typescript/ts-reset/pull/125#issuecomment-1926133512cc @tychenjiajun @younho9