key-by.js 351 B

1234567891011
  1. 'use strict';
  2. require('../../modules/es.map');
  3. require('../../modules/esnext.map.key-by');
  4. var path = require('../../internals/path');
  5. var Map = path.Map;
  6. var mapKeyBy = Map.keyBy;
  7. module.exports = function keyBy(source, iterable, keyDerivative) {
  8. return mapKeyBy.call(typeof this === 'function' ? this : Map, source, iterable, keyDerivative);
  9. };