Big changes on API and Frontend
This commit is contained in:
11
frontend/src/util/date.js
Normal file
11
frontend/src/util/date.js
Normal file
@@ -0,0 +1,11 @@
|
||||
const timestampToTime = (timestamp) => {
|
||||
const date = new Date(timestamp);
|
||||
return date.toLocaleTimeString();
|
||||
}
|
||||
|
||||
const timestampToDate = (timestamp) => {
|
||||
const date = new Date(timestamp);
|
||||
return date.toLocaleDateString();
|
||||
}
|
||||
|
||||
export { timestampToTime, timestampToDate };
|
||||
Reference in New Issue
Block a user