( token, date, _baseDate, _options, )
| 36 | }; |
| 37 | |
| 38 | export const formatRelative: FormatRelativeFn = ( |
| 39 | token, |
| 40 | date, |
| 41 | _baseDate, |
| 42 | _options, |
| 43 | ) => { |
| 44 | const format = formatRelativeLocale[token]; |
| 45 | |
| 46 | if (typeof format === "function") { |
| 47 | return format(date); |
| 48 | } |
| 49 | |
| 50 | return format; |
| 51 | }; |