Reorganize frontend and install Craco to alias modules (#190)
This commit is contained in:
11
front/src/modules/utils/utils.ts
Normal file
11
front/src/modules/utils/utils.ts
Normal file
@ -0,0 +1,11 @@
|
||||
export const humanReadableDate = (date: Date) => {
|
||||
return new Intl.DateTimeFormat(undefined, {
|
||||
month: 'short',
|
||||
day: 'numeric',
|
||||
year: 'numeric',
|
||||
}).format(date);
|
||||
};
|
||||
|
||||
export const getLogoUrlFromDomainName = (domainName?: string): string => {
|
||||
return `https://api.faviconkit.com/${domainName}/144`;
|
||||
};
|
||||
Reference in New Issue
Block a user