refactor: move more files to typescript
This commit is contained in:
20 files changed
+123
-177
No files matched your search
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* @format
|
||||
* @param {string} date - Date from server
|
||||
* @returns {string} Formated Date
|
||||
*/
|
||||
|
||||
export const formateDate = (date: string | number | Date) => {
|
||||
const dateObj = new Date(date);
|
||||
const formatedDate = new Intl.DateTimeFormat().format(dateObj);
|
||||
return formatedDate;
|
||||
};
|
||||
Reference in new issue
Block a user