Array.prototype.toObjectByProperty( element=>element.property )
Naveen Chawla
naveen.chwl at gmail.com
Fri Aug 11 04:11:30 UTC 2017
`Map.fromIterable(allThePeople, person=>person.name)` is less verbose for
your use case
On Fri, 11 Aug 2017 at 03:54 Alexander Jones <alex at weej.com> wrote:
> As far as I'm concerned, "most data arrays" — at least the ones you're
> speaking about — should actually be `Map`s.
>
Why? What's the advantage?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20170811/7b176d42/attachment.html>
More information about the es-discuss
mailing list