In this chapter, you'll learn about many new features of arrays in ES2015+, including new features for traditional arrays and the new typed arrays.
Before getting into the meat of the chapter, a brief note about terminology: There are a couple of words used to refer to the contents of arrays, the two most popular being “elements” and “entries.” Although “elements” is probably used slightly more often than “entries,” I use “entries” in this book to avoid confusion with DOM elements and because it's the name of the method on arrays,
NEW ARRAY METHODS
ES2015 (primarily), ES2016, and ES2019 added a host of new array methods, both for creating arrays and for accessing and modifying their contents.
arrayObject = Array.of(value0[, value1[, … ]])
Array.of creates and returns an array containing the values you pass to it as discrete arguments. For instance:
const a = Array.of("one", "two", "three");
console.log(a); // ["one", "two", ...