Detalhes do pacote

rc-color

Twinkle06927MIT1.0.0

Grab the color palette from an image using just Javascript in the browser and in Node

color, dominant-color, image-color, rc-color

readme (leia-me)

rc-color

Grab the color palette from an image using just Javascript in the browser and in Node.js

Installation

npm i rc-color

or

yarn add rc-color

Usage

Get the Dominant Color from an Image

const { getColorFromURL } = require('rc-color');

(async () => {
    const dominantColor = await getColorFromURL(imageURL);
})();

Build a Color Palette from an Image

const { getPaletteFromURL } = require('rc-color');

(async () => {
    const colorPallete = await getPaletteFromURL(imageURL);
})();