colors-ext
v1.0.3
Published
npm package for use colors in console
Downloads
316
Readme
Install
npm package for use colors in console
npm i colors-ext
Use
import 'colors-ext'; // es6
// require('colors-extension')
// console.log('text'.colorByNumber(30)) equals, 30 = black in ansi colors
console.log('black'.black());
console.log('red'.red());
console.log('green'.green());
console.log('yellow'.yellow());
console.log('blue'.blue());
console.log('magenta'.magenta());
console.log('cyan'.cyan());
console.log('white'.white());
console.log('blackBg'.blackBg());
console.log('redBg'.redBg());
console.log('greenBg'.greenBg());
console.log('yellowBg'.yellowBg());
console.log('blueBg'.blueBg());
console.log('magentaBg'.magentaBg());
console.log('cyanBg'.cyanBg());
console.log('whiteBg'.whiteBg());
console.log('you can merge foreground color with background color'.black().yellowBg());