Intl.RelativeTimeFormat
Input
Output
unit
{
value: "year",
style: "long",
numeric: "auto"
}
in 2 years
{
value: "years",
style: "long",
numeric: "auto"
}
in 2 years
{
value: "quarter",
style: "long",
numeric: "auto"
}
in 2 quarters
{
value: "quarters",
style: "long",
numeric: "auto"
}
in 2 quarters
{
value: "month",
style: "long",
numeric: "auto"
}
in 2 months
{
value: "months",
style: "long",
numeric: "auto"
}
in 2 months
{
value: "week",
style: "long",
numeric: "auto"
}
in 2 weeks
{
value: "weeks",
style: "long",
numeric: "auto"
}
in 2 weeks
{
value: "day",
style: "long",
numeric: "auto"
}
in 2 days
{
value: "days",
style: "long",
numeric: "auto"
}
in 2 days
{
value: "hour",
style: "long",
numeric: "auto"
}
in 2 hours
{
value: "hours",
style: "long",
numeric: "auto"
}
in 2 hours
{
value: "minute",
style: "long",
numeric: "auto"
}
in 2 minutes
{
value: "minutes",
style: "long",
numeric: "auto"
}
in 2 minutes
{
value: "second",
style: "long",
numeric: "auto"
}
in 2 seconds
{
value: "seconds",
style: "long",
numeric: "auto"
}
in 2 seconds