Node-Red configuration
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

esnext.reflect.define-metadata.js 717B

1234567891011121314151617
  1. 'use strict';
  2. // TODO: Remove from `core-js@4`
  3. var $ = require('../internals/export');
  4. var ReflectMetadataModule = require('../internals/reflect-metadata');
  5. var anObject = require('../internals/an-object');
  6. var toMetadataKey = ReflectMetadataModule.toKey;
  7. var ordinaryDefineOwnMetadata = ReflectMetadataModule.set;
  8. // `Reflect.defineMetadata` method
  9. // https://github.com/rbuckton/reflect-metadata
  10. $({ target: 'Reflect', stat: true }, {
  11. defineMetadata: function defineMetadata(metadataKey, metadataValue, target /* , targetKey */) {
  12. var targetKey = arguments.length < 4 ? undefined : toMetadataKey(arguments[3]);
  13. ordinaryDefineOwnMetadata(metadataKey, metadataValue, anObject(target), targetKey);
  14. }
  15. });