Use stringi::stri_datetime_format()
instead:
stringi::stri_datetime_format(format = c("date_short", "date_medium", "date_long", "date_full"),
locale = "en")
Usage
prettify_date(date, locale = c("en", "de", "en-US", "de-CH"))
Arguments
- date
Date to be prettified. A date or something coercible to.
- locale
Locale the date should be prettified for. Currently only
"en"
/"en-US"
and"de"
/"de-CH"
are implemented.
Details
Note that prettify_date()
might only work on (Ubuntu) Linux in the current form since locales are one bitchy hell of a PITA...
See also
Other spoken language functions:
add_definite_article_de()
,
decline_noun_de()
,
definite_article_de()
,
definite_article_de_declined()
,
n_ify()
,
phrase_datetime()
,
prettify_datetime()
,
rank_nr()
,
write_out_n()
Examples
salim:::prettify_date("2021-12-21")
#> Warning: `prettify_date()` was deprecated in salim 0.0.9015.
#> ℹ Use the more powerful and more robust `stringi::stri_datetime_format(format = c("date_short", "date_medium", "date_long", "date_full"), locale = "en")`
#> function instead.
#> [1] "December 21, 2021"