Skip to content
This repository has been archived by the owner on Mar 14, 2024. It is now read-only.

Latest commit

 

History

History
100 lines (59 loc) · 1.76 KB

README.md

File metadata and controls

100 lines (59 loc) · 1.76 KB

Badge Stars    Badge Deno



RGB

Convert colors to RGB.


Button Usage    Button Conversions



Examples


import * as RGB from 'https://deno.land/x/rgb/mod.ts';

Hex

const hex = '#0000FF'; // Blue

const rgb = RGB.fromHex(hex);

console.log(rgb); // [ 0 , 0 , 255 ]

HSL

const hsl = [ 0 , 100 , 50 ]; // Red

const rgb = RGB.fromHSL(hsl);

console.log(rgb); // [ 255 , 0 , 0 ]