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.

es.date.to-primitive.js 561B

1234567891011121314
  1. 'use strict';
  2. var hasOwn = require('../internals/has-own-property');
  3. var defineBuiltIn = require('../internals/define-built-in');
  4. var dateToPrimitive = require('../internals/date-to-primitive');
  5. var wellKnownSymbol = require('../internals/well-known-symbol');
  6. var TO_PRIMITIVE = wellKnownSymbol('toPrimitive');
  7. var DatePrototype = Date.prototype;
  8. // `Date.prototype[@@toPrimitive]` method
  9. // https://tc39.es/ecma262/#sec-date.prototype-@@toprimitive
  10. if (!hasOwn(DatePrototype, TO_PRIMITIVE)) {
  11. defineBuiltIn(DatePrototype, TO_PRIMITIVE, dateToPrimitive);
  12. }