Matthew
@matthew
TIL you can just do .filter(Boolean) instead of .filter((prop) => !!prop)
6 replies
1 recast
20 reactions
Darryl Yeo đ ïž
@darrylyeo
Itâs obsolete as of yesterdayâs TypeScript candidate release, but I had an `isTruthy` helper function wrapping `Boolean()` that included proper type narrowing too.
1 reply
0 recast
1 reaction
Matthew
@matthew
of course it is lol
1 reply
0 recast
1 reaction