@instantdb/core
Version:
Instant's core local abstraction
16 lines • 499 B
TypeScript
/**
* Stable, non-cryptographic 64-bit hash.
*
* We aren't concerned with the hash being decoded.
*
* We _do_ want to make sure hashes remain the same, even
* when objects undergo serializing and deserializing.
*
* Inspired by cyrb53 (Math.imul + xxhash-style avalanche).
* https://stackoverflow.com/a/52171480
*
* @param {any} input - Value to hash
* @returns {string} - Hash in hex format
*/
export default function weakHash(input: any): string;
//# sourceMappingURL=weakHash.d.ts.map