fix: resolve conflict in lib date
This commit is contained in:
@@ -64,4 +64,17 @@ export function getFormatDateId(date: Date) {
|
||||
const mm = monthsInId[date.getMonth()]
|
||||
const yyyy = date.getFullYear()
|
||||
return `${dd} ${mm} ${yyyy}`
|
||||
}
|
||||
return {
|
||||
idFormat,
|
||||
extFormat
|
||||
};
|
||||
}
|
||||
|
||||
export function formatDateYyyyMmDd(isoDateString: string): string {
|
||||
const date = new Date(isoDateString);
|
||||
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}`;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user