Created
April 21, 2022 07:43
-
-
Save thetminko/b05c92fc66a42053f4a4d59c43bf4bb5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export enum DateFormat { | |
// ISO 8601 | |
API_DATE = 'YYYY-MM-DD', | |
API_DATETIME = 'YYYY-MM-DDTHH:mm:ssZ', | |
API_TIME = 'HH:mm:ss', | |
// These should be the standardized formats for displaying date/time on frontend, | |
// if designers' designs show otherwise, we should advise them to standardize the format by using these | |
DISPLAY_DATE = 'DD MMM YYYY', | |
DISPLAY_DATETIME = 'DD MMM YYYY, h:mm A', | |
DISPLAY_TIME = 'h:mm A', | |
DISPLAY_MONTH_YEAR = 'MMM YY', | |
// Picker components | |
PICKER_DATE = 'DD/MM/YYYY', | |
PICKER_DATETIME = 'DD/MM/YYYY, h:mm A', | |
PICKER_TIME = 'h:mm A', | |
// MySQL | |
MYSQL_DATE = 'YYYY-MM-DD', | |
MYSQL_DATETIME = 'YYYY-MM-DD HH:mm:ss', | |
MYSQL_TIME = 'HH:mm:ss' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment