You're Invited: Meet the Socket team at BSidesSF and RSAC - April 27 - May 1.RSVP
Socket
Sign inDemoInstall
Socket

typescript-color-converter

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

typescript-color-converter

it is used to convert rgb to hex and vice versa

0.0.3
latest
Source
npm
Version published
Weekly downloads
1
-50%
Maintainers
1
Weekly downloads
 
Created
Source

color-converter

color-converter, it is used to obtain color value with .ts support;

Typescript Color Converter

npm install  typescript-color-converter --save

Usage

index.ts

import {RGBtoHEX, HEXtoRGB, colors} from 'typescript-color-converter';

function convertHexToRgb(hexvalue: string) {
    const convertedRGB = HexToRGB(rgbvalue);
    return convertedRGB;
}

function convertRgbToHex(rgbvalue) {
    const convertedHex = RGBtoHEX(rgbvalue);
}

colors.red //[255,0,0]

Keywords

color-converter

FAQs

Package last updated on 17 May 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts