DEV Community

Discussion on: 9 Extremely Powerful JavaScript Hacks

Collapse
 
mattsmithjs profile image
MattSmith-JS • Edited

Thanks a lot Klaus.
I've been using #1 (replace + regex + global flag) heaps since reading about it here. 7 is cool. I thought JS coercion might've turned the function into a boolean, but evidently it doesn't. Thanks again.