Skip to content

ionited/art

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Art

Art example

Art in your terminal

Quick start

Install with NPM

npm i @ionited/art

Usage

Require the package in your Node.js file:

const art = require('@ionited/art');

ANSI 8 Colors

Display ANSI 8 Colors (black, red, green, yellow, blue, magenta, cyan, white):

art.blue('Hey! I am blue!');

Brighter colors

For brighter color put 'bright' before the color:

art.brightRed('Hey! I am brighter red!');

Background colors

For background color put 'bg' before the color:

art.bgYellow('Hey! I have yellow background!');

Background colors also working with bright prefix:

art.bgBrightGreen('Hey! I have brighter green background!');

Modificators

Style your texts with modificators (bold, dim, italic, underline, blink, inverse, invisible, strikethrough):

art.bold('Hey! I am a bold text!');

You can join styles and make art in your terminal:

art.bgGreen.bold.yellow('A beatiful message!');

Animations

Make loadings or other animations easily:

art.animation(frames: any, infinite?: boolean, fps?: number): void

Example:

art.animation(['#', '##', '###', '####', '#####']);