Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

colorlab

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

colorlab

Library to calculate DeltaE (CIEDE2000) values between two colors

  • 0.2.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

colorlab

colorLab is a Javascript Lib to calculate DeltaE (CIEDE2000) values between two colors.

installation

npm install colorlab

DeltaE 2000 of two CIELAB colors

import colorlab from colorlab;

let color1 = new colorlab.CIELAB(50.0000, 2.6772, -79.7751);
let color2 = new colorlab.CIELAB(50.0000, 0.0000, -82.7485);

// CIEDE2000 tells you the DeltaE, or perceptible color
// difference, between CIELAB color1 and CIELAB color2

color1.CIEDE2000(color2); // => 2.0425
// or
colorlab.CIEDE2000(color1, color2); // => 2.0425

Contribut

npm Scripts

  • npm test - Lint the library and tests, then run the unit tests
  • npm run lint - Lint the source and unit tests
  • npm run watch - Continuously run the unit tests as you make changes to the source and test files themselves
  • npm run test-browser - Build the library for use with the browser spec runner. Changes to the source will cause the runner to automatically refresh.
  • npm run build - Lint then build the library
  • npm run coverage - Generate a coverage report

Browser Tests

The browser spec runner can be opened in a browser to run your tests. For it to work, you must first run npm run test-browser. This will set up a watch task that will automatically refresh the tests when your scripts, or the tests, change. The spec runner file is located at test/runner.html: open it in your browser to run tests.

Authors


See AUTHORS.txt.

Liks

Similar Libs

  • chromatist
  • CSS Color Module Level 4
  • Color-diff
  • ColorMine

Others

Travis build status Code Climate Test Coverage Dependency Status devDependency Status

FAQs

Package last updated on 09 May 2017

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc