1.0.15 • Published 3 years ago

@badcj/colours v1.0.15

Weekly downloads
-
License
ISC
Repository
github
Last release
3 years ago

@badcj/colours

@badcj/colours is a simple and lightweight JavaScript library for decorating text in cli.

Installation

Use the node package manager to install @badcj/colours.

npm install @badcj/colours

Usage

const {colouredText} = require('@badcj/colours');

console.log( colouredText().red("<<THIS WILL BE RED>>") );

console.log( colouredText().blue("<<THIS WILL BE BLUE AND UNDERLINED>>",['Underscore']) );

console.log( colouredText().white("<THIS WILL BE WHITE AND UNDERLINED WITH GREEN BACKGROUND>>",['Underscore','Green']) );

Results

alt text

Options

Current supported colours for text and background are :

  • black
  • red
  • green
  • yellow
  • blue
  • magenta
  • cyan
  • white

And supported decorations are :

  • Bright
  • Dim
  • Underscore
  • Blink
  • Reverse
  • Hidden

For Background color , just write the supported colour name in Pascal case in decorations array.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

1.0.15

3 years ago

1.0.14

3 years ago

1.0.13

3 years ago

1.0.12

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago