Constructor
new module:br/parsing/LocalisedDateParsingUtil()
Methods
-
parse(date, attributes) → {string}
-
Matches a date string and converts it to a specified output format.
Parameters:
Name Type Description datestring The date to parse attributesobject Map of configuration options Properties
Name Type Attributes Default Description inputFormatsArray.<string> The possible input formats, expressed with Moment.js format tokens outputFormatstring The output format, expressed with Moment.js format tokens inputLocalestring <optional>
Locale override for the input outputLocalestring <optional>
Locale override for the output endOfUnitboolean <optional>
false If true, parse ambiguous dates to the end of the month or year Returns:
The date, expressed in the output format- Type
- string