MCPcopy Create free account
hub / github.com/angular/dev-infra / buildDateStamp

Function buildDateStamp

ng-dev/release/notes/context.ts:254–260  ·  view source on GitHub ↗
(date = new Date())

Source from the content-addressed store, hash-verified

252 * Uses the current date, or a provided date in the format of YYYY-MM-DD, i.e. 1970-11-05.
253 */
254export function buildDateStamp(date = new Date()) {
255 const year = `${date.getFullYear()}`;
256 const month = `${date.getMonth() + 1}`.padStart(2, '0');
257 const day = `${date.getDate()}`.padStart(2, '0');
258
259 return [year, month, day].join('-');
260}

Callers 1

RenderContextClass · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected