feat: add email blocklist section with mocked data (#3145)

* feat: add email blocklist section with mocked data

* fix:front lint testcase

* fix: add current date and placeholder update

---------

Co-authored-by: Lakshay saini <lakshay.saini@finmo.net>
This commit is contained in:
Lakshay saini
2023-12-27 19:24:48 +05:30
committed by GitHub
parent a4e45d039e
commit c08d8ef838
8 changed files with 201 additions and 1 deletions

View File

@ -33,7 +33,10 @@ export const parseDate = (dateToParse: Date | string | number) => {
const isSameDay = (a: DateTime, b: DateTime): boolean =>
a.hasSame(b, 'day') && a.hasSame(b, 'month') && a.hasSame(b, 'year');
const formatDate = (dateToFormat: Date | string | number, format: string) => {
export const formatDate = (
dateToFormat: Date | string | number,
format: string,
) => {
try {
const parsedDate = parseDate(dateToFormat);
return parsedDate.toFormat(format);