MCPcopy Create free account
hub / github.com/arktypeio/arktype / dateKeyOf

Function dateKeyOf

ark/schema/parse.ts:432–439  ·  view source on GitHub ↗
(v: Date)

Source from the content-addressed store, hash-verified

430 : `${v}`
431
432const dateKeyOf = (v: Date): string => {
433 const time = timeOf(v)
434 return (
435 time === undefined ? `$${nameOf(v)}`
436 : Number.isNaN(time) ? "d'Invalid Date'"
437 : `d'${v.toISOString()}'`
438 )
439}
440
441// props of a value without an alias are found by key before parsing
442export const requiredPropOf = (

Callers 1

literalKeyOfFunction · 0.85

Calls 2

timeOfFunction · 0.90
nameOfFunction · 0.90

Tested by

no test coverage detected