Author image

Alexander von Studnitz

I'm a Computer Science student at TU Darmstadt and work as a Software Engineer at clickbar. Always looking to simplify things.

Grouping an array of objects by key

With the help of array.reduce, the Map data structure and higher-order functions you can do a lot in JavaScript, for example a generic groupBy function for an array of objects.

Link