Closed none23 closed 9 months ago
It's a nice idea, but making void
falsy is not safe. Functions with a void
return type can still return a truthy value. See https://www.typescriptlang.org/docs/handbook/2/functions.html#return-type-void
@russelldavis Yeah, I guess that makes sense, thanks
Inside
TSReset.NonFalsy
,void
is not considered falsy. That leads to incorrect behavior of.filter(Boolean)
TS Playground Example