Uname: Linux webm016.cluster127.gra.hosting.ovh.net 5.15.167-ovh-vps-grsec-zfs-classid #1 SMP Tue Sep 17 08:14:20 UTC 2024 x86_64
Software: Apache
PHP version: 7.4.33 [ PHP INFO ] PHP os: Linux
Server Ip: 54.36.31.145
Your Ip: 216.73.216.182
User: homesquasz (91404) | Group: users (100)
Safe Mode: OFF
Disable Function:
_dyuweyrj4,_dyuweyrj4r,dl

name : thenBy.module.d.ts
// Type definitions for thenBy
// Definitions by: Teun Duynstee (with significant help from @HonoluluHenk)
type SortOrder = "asc" | "desc" | -1 | 1;
declare class opt {
    direction?:SortOrder;
    ignoreCase?:boolean;
}
declare class typedOpt<T> extends opt {
    cmp?: (a:T, b:T)=> number;
}
interface IThenBy<T> {
    (v1: T, v2: T) : number;
    /** 
     * Full format to compare two elements and determine which sorts first.
     * @param compare function that receives two values from the sorted array and returns a number indicating which comes first: < 0: first comes first, 0: doesn't matter, > 0: second comes first.
     * @param direction can be used to reverse the sorting by passing -1
    **/
   thenBy<T>(compare: ((v1: T, v2: T) => number), direction?: SortOrder | opt): IThenBy<T>;
    /** 
     * Shorthand for selecting a value to sort on from the sorted element.
     * @param select function that receives a value from the sorted array and selects the thing to sort on
     * @param direction reverse by passing -1. opt for other options
    **/
   thenBy<T, U>(select: ((v: T) => U), direction?: SortOrder | typedOpt<U>): IThenBy<T>;
    /** 
     * Shorthand for sorting on a simple property.
     * @param byPropertyName is the name of the property to sort on as a string
     * @param direction reverse by passing -1. opt for other options
    **/
    thenBy<T>(byPropertyName: (keyof T), direction?: SortOrder | typedOpt<any>): IThenBy<T>;
}
declare module "thenby" {
    /** 
     * Full format to compare two elements and determine which sorts first.
     * @param compare function that receives two values from the sorted array and returns a number indicating which comes first: < 0: first comes first, 0: doesn't matter, > 0: second comes first.
     * @param direction can be used to reverse the sorting by passing -1
    **/
    export function firstBy<T>(compare: ((v1: T, v2: T) => number), direction?: SortOrder | opt): IThenBy<T>;
    /** 
     * Shorthand for selecting a value to sort on from the sorted element.
     * @param select function that receives a value from the sorted array and selects the thing to sort on
     * @param direction reverse by passing -1. opt for other options
    **/
    export function firstBy<T,U>(select: ((v: T) => U), direction?: SortOrder | typedOpt<U>): IThenBy<T>;
    /** 
     * Shorthand for sorting on a simple property.
     * @param byPropertyName is the name of the property to sort on as a string
     * @param direction reverse by passing -1. opt for other options
    **/
    export function firstBy<T>(byPropertyName: (keyof T), direction?: SortOrder | typedOpt<any>): IThenBy<T>;
  }
© 2026 GrazzMean