proposal-collection-methods icon indicating copy to clipboard operation
proposal-collection-methods copied to clipboard

Results 26 proposal-collection-methods issues
Sort by recently updated
recently updated
newest added

`Set` sorely lacks a `toggle` method: ```javascript Set.prototype.toggle = function (value, toggle = this.has(value)) { return toggle ? this.delete(value) : this.size < this.add(value).size } ```

Was wondering what the status of this proposal was, given that it's not listed on the [TC39 Proposals page.](https://github.com/tc39/proposals). Based on an [EDiscuss thread](https://esdiscuss.org/topic/new-set-methods-again) I'm wondering if this has stalled?

```js const aSet = new Set([1, 2, 3, 4]) console.log(aSet.at(1)) // 2 // Would be _really_ nice: console.log(aSet[1]) // 2 ```

Now this method is a part of [the `Array` grouping proposal](https://github.com/tc39/proposal-array-grouping), shipped in V8 and FF, and [most likely it will become a part of the stable ES in a...

![2023-11-11_23-39-17](https://github.com/tc39/proposal-collection-methods/assets/2213682/c28ab200-828e-4f8b-a45d-14f485f0bdc6) vs ![2023-11-11_23-40-01](https://github.com/tc39/proposal-collection-methods/assets/2213682/8dc9a4fe-e076-4601-ae0c-dd5d244eb21a) `Set` method returns a boolean, the rest - `this`. I raised this issue in the `Set` methods proposal, https://github.com/tc39/proposal-set-methods/issues/15, it was changed, and after that this method...

The `value `here is not defined, should it be `element`? https://github.com/tc39/proposal-collection-methods/blob/99480f94980a69efd1f24bdd7381f571d688f53d/map-polyfill.js#L117

Why do you add new methods instead of making `.add()` and `.delete()` work with several values? It will not break anything. The more names, the worse. There is no `.pushAll()`.

Bumps [qs](https://github.com/ljharb/qs) from 6.5.2 to 6.5.3. Changelog Sourced from qs's changelog. 6.5.3 [Fix] parse: ignore __proto__ keys (#428) [Fix] utils.merge`: avoid a crash with a null target and a truthy...

dependencies

As per previous discussions, Set and Map have the inherrent order (insertion order). Its possible to control it at creation time (by sorting initial iterable), but its not easy to...

Bumps [pathval](https://github.com/chaijs/pathval) from 1.1.0 to 1.1.1. Release notes Sourced from pathval's releases. v1.1.1 Fixes a security issue around prototype pollution. Commits db6c3e3 chore: v1.1.1 7859e0e Merge pull request #60 from...

dependencies