UNPKG

fast-string-compare

Version:

A (much) faster String.prototype.localeCompare

8 lines (7 loc) 232 B
/** * Compare two strings. This comparison is not linguistically accurate, unlike * String.prototype.localeCompare(), albeit stable. * * @returns -1, 0 or 1 */ export declare function compare(a: string, b: string): 0 | 1 | -1;