@stembord/hash
TypeScript icon, indicating that this package has built-in type declarations

0.1.1 • Public • Published

ts-hash

non secure hash function

import { hash } from "@stembord/hash";

hash(0); // 0
hash(42); // 42
hash(Infinity); // 0
hash(NaN); // 0
hash(true); // 1108378657
hash(false); // 1108378656
hash("Hello // world!"); // -806302731
hash([0, 1, 2]); // 1
hash({ key: "value" }); // 2

Readme

Keywords

Package Sidebar

Install

npm i @stembord/hash

Weekly Downloads

1

Version

0.1.1

License

(MIT OR Apache-2.0)

Unpacked Size

28.1 kB

Total Files

13

Last publish

Collaborators

  • jwaterfaucett
  • nathanfaucett