The various array methods in JavaScript can be thought of on a scale of power, or really flexibility. At the top end you've got the for
loop, at the bottom the highly-specific functions .every
and .some
. Jesse makes the argument that you should always choose the least powerful option and I agree. The article is also just a generally excellent overview of array manipulation in JavaScript.
- Source
- Link to Original 🔗
- Published
- Categories
- JavaScript
- Tags
- array, function, map, reduce, filter, find, forEach, for loop, JavaScript
Explore Other Notes
⬅ Newer
Turn music into visual magic
Astrofox looks like a really clever video editor, developed specifically with the aim of creating videos for music playlists and personal tracks. Nothing too fancy, but lots of options to animate …
Older ➡
Digital garden seedlings
Whilst falling down the rabbit-hole of digital gardening I found some of Maggie's tweets incredibly insightful and useful, yet somehow totally missed her own digital garden (and her entire related …
- <!DOCTYPE html> <html> <head> <title></title> </head> <body> <p>The various array methods in JavaScript can be thought of on a scale of <em>power</em>, or really flexibility. At the top end you've got the for loop, at the bottom the highly-specific functions …</p> </body> </html>
- Murray Champernowne