MCPcopy Create free account
hub / github.com/ZenNotes/zennotes / isValidIsoDate

Function isValidIsoDate

src/shared/tasks.ts:92–96  ·  view source on GitHub ↗
(s: string)

Source from the content-addressed store, hash-verified

90}
91
92function isValidIsoDate(s: string): boolean {
93 if (!/^\d{4}-\d{2}-\d{2}$/.test(s)) return false
94 const t = Date.parse(`${s}T00:00:00Z`)
95 return Number.isFinite(t)
96}
97
98function normalizeDueDate(raw: string | undefined): string | undefined {
99 if (!raw) return undefined

Callers 2

normalizeDueDateFunction · 0.70
extractTokensFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected