source: imaps-frontend/node_modules/es-abstract/helpers/OwnPropertyKeys.js

main
Last change on this file was d565449, checked in by stefan toskovski <stefantoska84@…>, 4 weeks ago

Update repo after prototype presentation

  • Property mode set to 100644
File size: 706 bytes
Line 
1'use strict';
2
3var GetIntrinsic = require('get-intrinsic');
4
5var callBind = require('call-bind');
6var callBound = require('call-bind/callBound');
7
8var $ownKeys = GetIntrinsic('%Reflect.ownKeys%', true);
9var $pushApply = callBind.apply(GetIntrinsic('%Array.prototype.push%'));
10var $SymbolValueOf = callBound('Symbol.prototype.valueOf', true);
11var $gOPN = GetIntrinsic('%Object.getOwnPropertyNames%', true);
12var $gOPS = $SymbolValueOf ? GetIntrinsic('%Object.getOwnPropertySymbols%') : null;
13
14var keys = require('object-keys');
15
16module.exports = $ownKeys || function OwnPropertyKeys(source) {
17 var ownKeys = ($gOPN || keys)(source);
18 if ($gOPS) {
19 $pushApply(ownKeys, $gOPS(source));
20 }
21 return ownKeys;
22};
Note: See TracBrowser for help on using the repository browser.