The function returns a text representing a time duration, i.e. a subtraction of two date-time values, using the current user's language.
formatDuration(duration) #Output: Text
This function is extremely helpful when you want to automatically calculate the duration in JWT calculated text fields.
If you prefer a more comprehensive representation, have a look at the shortFormatDuration() function.
formatDuration() | shortFormatDuration() |
---|---|
"1 day, 11 hours, 30 minutes" . | "1d 11h 30m" |