@metreeca/core - v0.9.11
    Preparing search index...

    Function reverse

    • Reverses the order of a comparator.

      Returns a new comparator that produces the opposite ordering of the original.

      Type Parameters

      • V

        The type of values to compare

      Parameters

      • comparator: (a: V, b: V) => number

        Comparator to reverse

      Returns (a: V, b: V) => number

      A comparator that produces the opposite ordering