Modern JavaScript: ES6 and beyond!
Plans from $25/month

This lesson is for members. Join us?

Subscribe now to get instant access to this course, plus a full library of Vue.js courses tailored to the plan you choose.

Learn Array.forEach and Array.map in JavaScript

In this lesson, we'll learn how to use two new array helper methods that was introduced to JavaScript in ES6, namely the Array.forEach and Array.map functions.

The forEach method lets us execute a callback function on each array element.

The map method lets us create a new array with the results of calling a callback on every element in the array.