monad-ts
Version:
Monad-ts is a small library implements some of key monads and way to chain them in a pipe (flow) in JavaScript and TypeScript. Angular 2+ compatible.
10 lines (9 loc) • 321 B
TypeScript
/**
* Calculates a hash (32 bit).
* Based on FNV-1a algorithm, ref: http://isthe.com/chongo/tech/comp/fnv/
* @method hash
* @param {string} str - string to hash
* @param {number} [pHash = 2166136261] previous hash.
* @returns {number}
*/
export declare function hash(str: string, pHash?: number): number;