Sha256: 7295b4f70005984ba36811929118dc3cff6191f082879817e08b66d2cb04ccc3
Contents?: true
Size: 743 Bytes
Versions: 4
Compression:
Stored size: 743 Bytes
Contents
'use strict'; var $ = require('../internals/export'); var uncurryThis = require('../internals/function-uncurry-this'); var aSet = require('../internals/a-set'); var iterate = require('../internals/set-iterate'); var toString = require('../internals/to-string'); var arrayJoin = uncurryThis([].join); var push = uncurryThis([].push); // `Set.prototype.join` method // https://github.com/tc39/proposal-collection-methods $({ target: 'Set', proto: true, real: true, forced: true }, { join: function join(separator) { var set = aSet(this); var sep = separator === undefined ? ',' : toString(separator); var array = []; iterate(set, function (value) { push(array, value); }); return arrayJoin(array, sep); } });
Version data entries
4 entries across 4 versions & 1 rubygems