Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #41421

Re: JavaScript now supports 'groupBy`

Newsgroups comp.lang.javascript
Date 2023-09-02 02:50 -0700
References <b5e3bf33-1b38-4bb1-b6f2-4fdb3348b2afn@googlegroups.com>
Message-ID <7bc9bbab-16dd-40e9-ba65-9377c0ea2fc3n@googlegroups.com> (permalink)
Subject Re: JavaScript now supports 'groupBy`
From Julio Di Egidio <julio@diegidio.name>

Show all headers | View raw


On Monday, 21 August 2023 at 20:42:18 UTC+2, Michael Haufe (TNO) wrote:

> In case you missed it, JavaScript finally implemented
> a groupBy static method for Object and Map

You might have missed that it's neither decently supported,
nor, as for the enthusiasm, it has anything to do with the
aggregation operator by the same name, in fact, with any
aggregation at all: this "groupBy" is more of a "partitionBy"
and can be implemented in one line of code with an array
reduce over the input's keys.  Indeed, I'd call it plain clutter.

Julio

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

JavaScript now supports 'groupBy` "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2023-08-21 11:42 -0700
  Re: JavaScript now supports 'groupBy` Julio Di Egidio <julio@diegidio.name> - 2023-09-02 02:50 -0700
    Re: JavaScript now supports 'groupBy` luserdroog <luser.droog@gmail.com> - 2023-09-03 06:10 -0700
    Re: JavaScript now supports 'groupBy` "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2023-09-03 07:55 -0700
      Re: JavaScript now supports 'groupBy` Julio Di Egidio <julio@diegidio.name> - 2023-09-03 08:18 -0700
    Re: JavaScript now supports 'groupBy` Mild Shock <janburse@fastmail.fm> - 2023-09-04 01:43 +0200
  Re: JavaScript now supports 'groupBy` Arno Welzel <usenet@arnowelzel.de> - 2023-09-03 17:39 +0200
    Re: JavaScript now supports 'groupBy` "Michael Haufe (TNO)" <tno@thenewobjective.com> - 2023-09-04 06:45 -0700

csiph-web