0.0.1 • Published 8 years ago

wordhex v0.0.1

Weekly downloads
26
License
MIT
Repository
github
Last release
8 years ago

wordhex

ES5 function to convert a string into a hex color code. The motivation behind this library is to be able to generate unique and repeatable hex color codes for people's names.

Install

npm install wordhex

Usage

var wordhex = require('wordhex');

// Returns '#1daeea'
wordhex('npm');

// Returns '#FFFFFF'
wordhex('');

// Returns '#78835e'
wordhex('github')

// Still returns '#1daeea'
wordhex('npm');
0.0.1

8 years ago