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

OmegaTools/RGB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


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 ]