Reference

Function Index

Complete API reference for all exported functions, classes, and types in color-schemes-js.

Function Index

Summary reference of exported functions and data structures provided by color-schemes-js:

Export / APIDescription
colorschemesRegistry dictionary object containing all pre-defined ColorScheme instances.
ColorSchemeConstructor for creating new colorscheme instances from arrays of colors.
get(scheme, t)Sample a scheme continuously at position t $\in 0.0, 1.0$.
resample(scheme, n)Generate a new ColorScheme by resampling an existing scheme with $n$ steps.
findcolorscheme(query)Search pre-defined scheme names, categories, and notes matching a search string or regular expression.
getInverse(scheme, color)Inverse lookup: find normalized position $t \in 0.0, 1.0$ corresponding to closest matching color in a scheme.
Copyright © 2026