David Bruant (2013-12-31T19:36:42.000Z)
Hi,

I've been playing with Sets recently and believe that the following 
additions would make them more useful by default:
* Set.prototype.map
* Set.prototype.filter
* Set.prototype.toJSON = function(){
     return [...this];
};

The 2 first are to easily create sets from existing sets very much like 
what we already have with arrays. I haven't had a use for a .reduce yet, 
but maybe that would make sense too?
The toJSON is just to provide a good default. Obviously anyone 
disatisfied with it can shadow it on specific instances. But this 
serialization makes more sense by default than the one you get now (own 
properties of the set object... which have none in common usages?)

Hopefully both IE11 and Firefox having shipped Sets without this toJSON 
behavior won't prevent this change?

David
domenic at domenicdenicola.com (2014-01-06T14:12:44.610Z)
I've been playing with Sets recently and believe that the following 
additions would make them more useful by default:

* `Set.prototype.map`
* `Set.prototype.filter`
* ```js
  Set.prototype.toJSON = function(){
     return [...this];
  };
  ```

The 2 first are to easily create sets from existing sets very much like 
what we already have with arrays. I haven't had a use for a .reduce yet, 
but maybe that would make sense too?
The toJSON is just to provide a good default. Obviously anyone 
disatisfied with it can shadow it on specific instances. But this 
serialization makes more sense by default than the one you get now (own 
properties of the set object... which have none in common usages?)

Hopefully both IE11 and Firefox having shipped Sets without this toJSON 
behavior won't prevent this change?