Skip to content

comparison-sorting/is-sorted

Repository files navigation

Order validation for JavaScript. See docs.

import {isSorted} from '@comparison-sorting/is-sorted';
import {increasing, decreasing} from '@total-order/primitive';
isSorted(increasing, [1, 2, 3], 0, 3); // true
isSorted(decreasing, [1, 2, 3], 0, 3); // false

License Version Tests Dependencies GitHub issues Downloads

Code issues Code maintainability Code coverage (cov) Code technical debt Documentation Package size