Dynamic Dates And Times In WordBoard Variables
WordBoard keys can type today's date or time automatically using the date variable, in any format you like.
The format is {{ date:"dd-MM-yyyy HH:mm" }} using the Unicode date format patterns. There's a great site to test out the formats at NSDateFormatter.com.
Examples:
| Wednesday, Nov 6, 2019 | {{ date:"EEEE, MMM d, yyyy" }} |
| 2019-11-06T07:19:11+0000 | {{ date:"yyyy-MM-dd'T'HH:mm:ssZ" }} |
| Wed, 6 Nov 2019 07:19:11 +0000 | {{ date:"E, d MMM yyyy HH:mm:ss Z" }} |
Using it in a phrase:
For example you could create a phrase:
Today is {{ date:"EEEE" }} and the month is {{ date:"MMM" }}
Which would print out something like:
Today is Wednesday and the month is Nov
Offsetting the time:
You can offset the time in hours:
{{ datehouroffset:"EEEE, MMM d, yyyy", 24 }}
or use a negative to go to the past
{{ datehouroffset:"EEEE, MMM d, yyyy", -8 }}
Other languages
Add a language code after the format to show day and month names in that language, for example {{ date:"EEEE", "de" }} types "Mittwoch".
Moving the time forward or back
{{ datehouroffset:"h:mm a", 3 }} shows the time 3 hours from now. Use a negative number to go back. The offset has to be a whole number of hours, and this variable doesn't take a language code.
Prefer not to type a format? Use a Date & Time Key from the + button and pick one of the ready-made formats.
Want text rewritten or translated instead? Try AI Keys.