colour-proximity

Get a value of the proximity of two hex colours.

colour-proximity

Get a value of the proximity of two hex colours.

colour-proximity.proximity("#ffffff","#fffffe") // 1 
colour-proximity.proximity("#ffffff","#000000") // 441.6729559300637 

Use node with npm:

npm install colour-proximity