( token, date, baseDate, options, )
| 71 | }; |
| 72 | |
| 73 | export const formatRelative: FormatRelativeFn = ( |
| 74 | token, |
| 75 | date, |
| 76 | baseDate, |
| 77 | options, |
| 78 | ) => { |
| 79 | const format = formatRelativeLocale[token]; |
| 80 | |
| 81 | if (typeof format === "function") { |
| 82 | return format(token, date, baseDate, options); |
| 83 | } |
| 84 | |
| 85 | return format; |
| 86 | }; |