string-hashcode

0.0.1 • Public • Published

string-hashcode

NPM version build status Test coverage

Extra utilities for string.

Install

npm install string-hashcode

Example

var hashCode = require('string-hashcode');
var s = 'abc';
 
console.log(s.hashCode); // undefined
var code = hashCode(s);
console.log(s.hashCode); // Function
 
var code2 = s.hashCode();
assert.equal(code, code2);

API

hashCode(str)

params:

  • str: string object

return:

Number: hash code

Return a hash code of a string. Note that a hash code is immutable with a certain string.

Lisence

MIT

Readme

Keywords

Package Sidebar

Install

npm i string-hashcode

Weekly Downloads

6

Version

0.0.1

License

none

Last publish

Collaborators

  • luckydrq