Creates a Predicate function that checks if all elements of an Iterable are monotonic sorted according to a Comparator.
Check if iterable is monotonic sorted
iterable
const isMonotoneSortedByNumber = isMonotone(numberComparator);const iterable = [1,2,3];const result = isMonotoneSortedByNumber(iterable);console.log(result); // true
the Predicate
the Iterable value type
the Comparator to use
Generated using TypeDoc
Creates a Predicate function that checks if all elements of an Iterable are monotonic sorted according to a Comparator.
Exmaple
Check if
iterableis monotonic sortedReturns
the Predicate