• Coerces value to the specified maximum precision. If the value has greater than the specified precision, then rounds the value to the specified precision. If the value has less than or equal to the specified precision, the value is unchanged.

    Parameters

    • value: number

      Source value to be evaluated

    • precision: number = 0

      Maximum number of characters after decimal point

    Returns number

    value rounded to the specified precision