Installation
npm install --save @types/array-sort
Summary
This package contains type definitions for array-sort (https://github.com/jonschlinkert/array-sort).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/array-sort.
index.d.ts
type Comparator<T> = (a: T, b: T) => number;
type ComparisonArg<T> = string | Comparator<T>;
type ComparisonArgs<T> = ComparisonArg<T> | Array<ComparisonArg<T>>;
interface Options {
readonly reverse: boolean;
}
declare function arraySort<T>(
arr: T[],
props?: ComparisonArgs<T>,
options?: Options,
): T[];
export default arraySort;
Additional Details
- Last updated: Mon, 06 Nov 2023 22:41:04 GMT
- Dependencies: none
Credits
These definitions were written by Daniel Schmidt.