r/javascript • • Mar 18 '19

What's your favorite, most useful javascript one-liner?

385 Upvotes

422 comments sorted by

View all comments

Show parent comments

1

u/fucking_passwords Mar 19 '19

But, NodeList has forEach... if you example used map or reduce it would make more sense

1

u/Sn34kyMofo Mar 19 '19

Indeed. My reply was simply meant to contribute, not dispute. Pick any other array-only method to use with my example instead. =)