1.0.0 • Published 3 years ago

murmur-128 v1.0.0

Weekly downloads
4,637
License
MIT
Repository
github
Last release
3 years ago

MurmurHash3 128-bit

MurmurHash3 x86 128-bit implemented in JavaScript.

Installation

npm install --save murmur-128

Usage

import murmur128 from 'murmur-128'

murmur128('linus')
//=> ArrayBuffer { 16 }

murmur128(new ArrayBuffer(10))
//=> ArrayBuffer { 16 }

API

murmur128(key)

  • key (ArrayBuffer | string, required)
  • returns ArrayBuffer

Compute the 128-bit MurmurHash3 of the supplied key. If the key is given as a string it will be encoded using the UTF8 encoding.

See also

  • murmur-32 - MurmurHash3 x86 32-bit implemented in JavaScript