Sha256: 3338e1a5c1a2d405e213703b30b2eccebfb78c5aff768f4591c55be2eda217b6
Contents?: true
Size: 690 Bytes
Versions: 66
Compression:
Stored size: 690 Bytes
Contents
// https://github.com/tc39/proposal-object-getownpropertydescriptors var $export = require('./_export'); var ownKeys = require('./_own-keys'); var toIObject = require('./_to-iobject'); var gOPD = require('./_object-gopd'); var createProperty = require('./_create-property'); $export($export.S, 'Object', { getOwnPropertyDescriptors: function getOwnPropertyDescriptors(object) { var O = toIObject(object); var getDesc = gOPD.f; var keys = ownKeys(O); var result = {}; var i = 0; var key, desc; while (keys.length > i) { desc = getDesc(O, key = keys[i++]); if (desc !== undefined) createProperty(result, key, desc); } return result; } });
Version data entries
66 entries across 30 versions & 8 rubygems