3.0.0 - TrueColor support and possible breaking change

@sindresorhus sindresorhus released this Jul 15, 2015 · 22 commits to master since this release

Possible breaking change

It will not work correctly if you're using strict true equality checking as the return type is now either an object or false, instead of previously, always a boolean. Falsy checking will continue to work fine.

Works

var supportsColor = require('supports-color');

if (supportsColor) {
  console.log('Supports color');
}

No longer works

var supportsColor = require('supports-color');

if (supportsColor === true) {
  console.log('Supports color');
}

TrueColor support

It can now detect what grade of color support your terminal have. Check out the readme for more info.

Downloads