Set constructor arguments

Peter Michaux petermichaux at
Sun Feb 12 16:33:58 PST 2012

In the proposal, the Set constructor takes no arguments.

Could it take a list of initial elements to be included in the set?

var s = new Set('alpha', 'beta');
s.has('alpha'); // true

I think this is a lot better than the verbosity that is

var s = new Set();


More information about the es-discuss mailing list