MCPcopy Index your code
hub / github.com/simstudioai/sim / toDateString

Function toDateString

packages/emcn/src/components/calendar/calendar.tsx:47–49  ·  view source on GitHub ↗

* Serializes a calendar cell to the `YYYY-MM-DD` wire format used across the * date filters. Built from local Y/M/D parts so there is no UTC offset shift.

(year: number, month: number, day: number)

Source from the content-addressed store, hash-verified

45 * date filters. Built from local Y/M/D parts so there is no UTC offset shift.
46 */
47function toDateString(year: number, month: number, day: number): string {
48 return `${year}-${pad2(month + 1)}-${pad2(day)}`
49}
50
51/**
52 * Parses a `YYYY-MM-DD` string (or `Date`) into a local `Date`. `YYYY-MM-DD`

Callers 3

buildRangeBoundsFunction · 0.85
selectDayFunction · 0.85
goToTodayFunction · 0.85

Calls 1

pad2Function · 0.70

Tested by

no test coverage detected