index.js 572 B

1234567891011121314151617181920212223
  1. 'use strict';
  2. var callBind = require('call-bind');
  3. var define = require('define-properties');
  4. var RequireObjectCoercible = require('es-object-atoms/RequireObjectCoercible');
  5. var implementation = require('./implementation');
  6. var getPolyfill = require('./polyfill');
  7. var shim = require('./shim');
  8. var bound = callBind(getPolyfill());
  9. var boundMethod = function trim(receiver) {
  10. RequireObjectCoercible(receiver);
  11. return bound(receiver);
  12. };
  13. define(boundMethod, {
  14. getPolyfill: getPolyfill,
  15. implementation: implementation,
  16. shim: shim
  17. });
  18. module.exports = boundMethod;