/* Code-Comments */

January 07, 2020

Package Discovery: gray-percentage

Today in package discoveries:1 gray-percentage.

It’s a small utility written by Kyle Matthews (creator of Gatsby) that returns a hue of gray (with an optional mixin for a color).

Kyle used this in Typography.JS, a quick theming library, which is how I found it. However, gray-percentage is more generally useful to find alternatives to black (#000) (https://ianstormtaylor.com/design-tip-never-use-black/).

Looking at the code, it also reminded me of the complementary color generator I published last year. The goal of that package was to use color theory to create complementary colors for use in data visualization (somewhat similar to a site like coolors.co).


  • 1 I can see this being an ongoing series of loosely related posts. This is the first one though.

Stephen Weiss

Thanks for reading! My name's Stephen Weiss. I live in Chicago with my wife, Kate, and dog, Finn.
Click here to see the archives of my weeks in review and sign up yourself!