• Deserializes a relative date string value into a valid RelativeDate object. Throws an error if the date is invalid.

    Parameters

    • date: string

      The string serialized with the format "period-amount-unit"

    Returns RelativeDate

    The parsed RelativeDate object.