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.

es.array.with.js 428B

1234567891011121314
  1. 'use strict';
  2. var $ = require('../internals/export');
  3. var arrayWith = require('../internals/array-with');
  4. var toIndexedObject = require('../internals/to-indexed-object');
  5. var $Array = Array;
  6. // `Array.prototype.with` method
  7. // https://tc39.es/ecma262/#sec-array.prototype.with
  8. $({ target: 'Array', proto: true }, {
  9. 'with': function (index, value) {
  10. return arrayWith(toIndexedObject(this), $Array, index, value);
  11. }
  12. });