Miss any of our Open RFC calls?Watch the recordings here! »

pwmcolorparser

1.1.1 • Public • Published

pwm-color-parser

JavaScript parser for PWM color values

Installation

npm install pwmcolorparser

Sample

var pwmColorParser = require('pwmcolorparser');
 
console.log(pwmColorParser.parseHex('#FF0000')); // outputs [100, 0, 0]
console.log(pwmColorParser.parseRGB([255, 0 , 0])) // outputs [100, 0, 0]
console.log(pwmColorParser.parseColor('red')); // outputs [100, 0, 0, 1]
 

Install

npm i pwmcolorparser

DownloadsWeekly Downloads

14

Version

1.1.1

License

MIT

Last publish

Collaborators

  • avatar