colorful

colorful if a terminal tool for colors

15 个版本
安装
npm install colorful
yarn add colorful
pnpm add colorful
bun add colorful
README

Colorful support for terminal


Color

color as function:

var color = require('colorful').color
color.red('hello')
color.underline('hello')

color as human:

require('colorful').colorful()
'hello'.to.red.color
'hello'.to.underline.bold.red.color

color and style supports:

  • black black_bg
  • red red_bg
  • green green_bg
  • yellow yellow_bg
  • blue blue_bg
  • magenta magenta_bg
  • cyan cyan_bg
  • white white_bg
  • gray grey gray_bg grey_bg
  • bold
  • italic
  • underline
  • blink
  • inverse
  • strike

and detect is color supported:

require('colorful').color.isSupported

Logging

Colorful and nested logging support.

版本列表
2.1.0 2013-05-22
2.0.3 2013-03-23
2.0.2 2013-03-22
2.0.1 2013-03-18
2.0.0 2013-03-18
1.3.0 2013-03-17
1.2.3 2013-01-25
1.2.2 2013-01-22
1.2.0 2013-01-06
1.1.2 2012-12-29
1.1.1 2012-12-27
1.1.0 2012-12-21
1.0.2 2012-12-10
1.0.1 2012-12-08
1.0.0 2012-12-07