The date to format.
Optional
mask: stringA format string that supports the following wildcards:
@y
- Full year (e.g., 2025
)@m
- Month number (1–12)@mm
- Month number with leading zero (01–12)@mmm
- Abbreviated month name (e.g., Jan
)@mmmm
- Full month name (e.g., January
)@d
- Day of the month (1–31)@dd
- Day with leading zero (01–31)@ddd
- Abbreviated weekday name (e.g., Sun
)@dddd
- Full weekday name (e.g., Sunday
)@w
- Week number (US system; starts at January 1st)@h
- Hour in 24-hour format (0–23)@hh
- Hour in 24-hour format with leading zero (00–23)@o
- Hour in 12-hour format (1–12)@oo
- Hour in 12-hour format with leading zero (01–12)@i
- Minutes (0–59)@ii
- Minutes with leading zero (00–59)@s
- Seconds (0–59)@ss
- Seconds with leading zero (00–59)@l
- Milliseconds (0–999)@ll
- Milliseconds with at least 2 digits (e.g., 09
, 95
, 120
)@lll
- Milliseconds with 3 digits (e.g., 009
, 095
, 120
)@e
- Lowercase meridiem (a/p)@ee
- Lowercase meridiem (am/pm)@eee
- Lowercase meridiem with dots (a.m./p.m.)@E
- Uppercase meridiem (A/P)@EE
- Uppercase meridiem (AM/PM)@EEE
- Uppercase meridiem with dots (A.M./P.M.)If no mask is provided, the PUtilsDate.format.defaultMask
is used.
Optional
language: PLanguagesOptional. Specifies the language for month and weekday names. If not provided, the global language is used.
A formatted date string based on the provided mask and language.
Formats a given date according to a custom mask and language.