Here contains the 36 complete Javascript array methods updated as may be contained both on w3 and Mozilla and other sources
Hence though I have updated the Javascript library on w3 and compiled it here, I recently deleted the since it is obsoleted Array.prototype.toSource()
Array.prototype.toSource() | .toSource() | Returns A string representing the source code of the array. |
The Complete Javascript Array Method
Number of arrays 36 currently as 03 July, 2020.
s/n | Array Methods | keywords | Uses |
1 | Array.from() | from() | Creates an array from an object |
2 | Array.isArray() | isArray() | Checks whether an object is an array |
3 | Array.of() | .of() | Returns A new Array instance. |
4 | Array.prototype.concat() | concat() | Joins two or more arrays |
5 | Array.prototype.copyWithin() | copyWithin() | Copies array elements within the array |
6 | Array.prototype.entries() | entries() | Returns a key/value pair Array Iteration Object |
7 | Array.prototype.every() | every() | Checks if every element in an array pass a test |
8 | Array.prototype.fill() | fill() | Fill the elements in an array with a static value |
9 | Array.prototype.filter() | filter() | Creates a new array with every element in an array that pass a test |
10 | Array.prototype.find() | find() | Returns the value of the first element in an array that pass a test |
11 | Array.prototype.findIndex() | findIndex() | Returns the index of the first element in an array that pass a test |
12 | Array.prototype.flat() | .flat() | Returns a new array with the sub-array elements concatenated into it. |
13 | Array.prototype.flatMap() | .flatMap() | Return new array with each element being the result of the callback function and flattened to a depth of 1. |
14 | Array.prototype.forEach() | forEach() | Calls a function for each array element |
15 | Array.prototype.includes() | includes() | Check if an array contains the specified element |
16 | Array.prototype.indexOf() | indexOf() | Search the array for an element and returns its position |
17 | Array.prototype.join() | join() | Joins all elements of an array into a string |
18 | Array.prototype.keys() | keys() | Returns a Array Iteration Object |
19 | Array.prototype.lastIndexOf() | lastIndexOf() | Search the array for an element |
20 | Array.prototype.map() | map() | Creates a new array with the result of calling a function for each array element |
21 | Array.prototype.pop() | pop() | Removes the last element of an array |
22 | Array.prototype.push() | push() | Adds new elements to the end of an array |
23 | Array.prototype.reduce() | reduce() | Reduce the values of an array to a single value (going left-to-right) |
24 | Array.prototype.reduceRight() | reduceRight() | Reduce the values of an array to a single value (going right-to-left) |
25 | Array.prototype.reverse() | reverse() | Reverses the order of the elements in an array |
26 | Array.prototype.shift() | shift() | Removes the first element of an array |
27 | Array.prototype.slice() | slice() | Selects a part of an array |
28 | Array.prototype.some() | some() | Checks if any of the elements in an array pass a test |
29 | Array.prototype.sort() | sort() | Sorts the elements of an array |
30 | Array.prototype.splice() | splice() | Adds/Removes elements from an array |
31 | Array.prototype.toLocaleString() | .toLocaleString() | Returns A string representing the elements of the array. |
32 | Array.prototype.toSource() | .toSource() | Returns A string representing the source code of the array. |
33 | Array.prototype.toString() | toString() | Converts an array to a string |
34 | Array.prototype.unshift() | unshift() | Adds new elements to the beginning of an array |
35 | Array.prototype.values() | valueOf() | Returns the primitive value of an array |
36 | Array.prototype[@@iterator]() | [@@iterator]() | Returns The initial value given by the values() iterator. By default, using arr[Symbol.iterator] will return the values() function. |
37 | get Array[@@species] | [@@species] | Returns The Array constructor. |
the 36 complete javascript array methods