es.reflect.get-own-property-descriptor.js 595 B

12345678910111213
  1. 'use strict';
  2. var $ = require('../internals/export');
  3. var DESCRIPTORS = require('../internals/descriptors');
  4. var anObject = require('../internals/an-object');
  5. var getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');
  6. // `Reflect.getOwnPropertyDescriptor` method
  7. // https://tc39.es/ecma262/#sec-reflect.getownpropertydescriptor
  8. $({ target: 'Reflect', stat: true, sham: !DESCRIPTORS }, {
  9. getOwnPropertyDescriptor: function getOwnPropertyDescriptor(target, propertyKey) {
  10. return getOwnPropertyDescriptorModule.f(anObject(target), propertyKey);
  11. }
  12. });