Node-Red configuration
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

esnext.set.add-all.js 487B

123456789101112131415
  1. 'use strict';
  2. var $ = require('../internals/export');
  3. var aSet = require('../internals/a-set');
  4. var add = require('../internals/set-helpers').add;
  5. // `Set.prototype.addAll` method
  6. // https://github.com/tc39/proposal-collection-methods
  7. $({ target: 'Set', proto: true, real: true, forced: true }, {
  8. addAll: function addAll(/* ...elements */) {
  9. var set = aSet(this);
  10. for (var k = 0, len = arguments.length; k < len; k++) {
  11. add(set, arguments[k]);
  12. } return set;
  13. }
  14. });