Sent on Jun 17, 2020

How I work with arrays

There are many flavours to arrays in JavaScript. The possible methods you to create or change arrays are: unshift, shift, push, pop, splice, concat, slice, destructuring, rest operators, and spread operators.

There are also looping methods like for, forEach, map, filter, reduce, find, findIndex.

17 different flavours!

I want to document how I choose the array methods I use. This should help you understand how to pick methods.

Click here to read the article!

What you’ll learn:

  1. How I add items to the start, middle, end of an array
  2. How I remove items from the start, middle, and end of an array
  3. How I work work with loops
  4. How I deal with asynchronous loops
  5. Why I prefer splice over slice sometimes (and apparently this is weird).

Here’s the article again.

Enjoy!

Stay awesome,
Zell