from.js 568 B

12345678910111213141516
  1. 'use strict';
  2. require('../../modules/es.array.iterator');
  3. require('../../modules/es.map');
  4. require('../../modules/es.string.iterator');
  5. require('../../modules/esnext.map.from');
  6. require('../../modules/web.dom-collections.iterator');
  7. var call = require('../../internals/function-call');
  8. var isCallable = require('../../internals/is-callable');
  9. var path = require('../../internals/path');
  10. var Map = path.Map;
  11. var $from = Map.from;
  12. module.exports = function from(source, mapFn, thisArg) {
  13. return call($from, isCallable(this) ? this : Map, source, mapFn, thisArg);
  14. };