Files
test-repo/scripts/release/get-formatted-date.js
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

8 lines
329 B
JavaScript
Raw Normal View History

2021-09-11 16:20:26 +09:00
// TODO: Implement this in `utils.js` when jest.importActual is landed.
export default function getFormattedDate() {
const date = new Date();
const year = date.getFullYear();
const month = String(date.getMonth() + 1).padStart(2, "0");
const day = String(date.getDate()).padStart(2, "0");
return { year, month, day };
}