extended-collectionsdeprecated

Implementations of ECMAScript/TC39 Collection proposals with additional utility methods

Usage no npm install needed!

<script type="module">
  import extendedCollections from 'https://cdn.skypack.dev/extended-collections';
</script>

README

Extended Collections

Modern polyfills of Stage 1 Collection Methods, including additional utility methods adapted from other languages, such as C#, Haskell, Python, Hack, and Ruby to make Collections even more versatile.

Map*

new Map([iterable[, handler]])

Static

Instance

*If a method can be called on both keys and values, the method will target the Map's values by default and will have an implementation which targets the Map's keys (e.g., .find and .findKey)
.mapValues is called .map for consistency
†† Adapted to work with Map

Planned

  • Map.prototype.flat
  • Map.prototype.flatMap

Set

new Set([iterable[, coerceValue]])

Static

Instance

* Adapted to work with Set

Planned

  • Set.prototype.flat
  • Set.prototype.flatMap