feat: didn't read the note lol
This commit is contained in:
parent
f89f9045e2
commit
b8900381d6
1 changed files with 5 additions and 0 deletions
5
index.js
5
index.js
|
|
@ -24,6 +24,11 @@ const groupedArray = array.reduce((newArray, item) => {
|
||||||
return newArray;
|
return newArray;
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
console.log(
|
||||||
|
`Here's your arrays in an array (ordered by first appearance):`,
|
||||||
|
groupedArray
|
||||||
|
);
|
||||||
|
|
||||||
groupedArray.sort((a, b) => {
|
groupedArray.sort((a, b) => {
|
||||||
const valueA = a[0];
|
const valueA = a[0];
|
||||||
const valueB = b[0];
|
const valueB = b[0];
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue