3.1.1 • Published 10 months ago

terminal-kit v3.1.1

Weekly downloads
29,546
License
MIT
Repository
github
Last release
10 months ago

★ License Downloads Version Run on repl.it

Stats

Terminal Kit

A full-blown terminal lib featuring: 256 colors, styles, keys & mouse handling, input field, progress bars, screen buffer (including 32-bit composition and image loading), text buffer, and many more...

Whether you just need colors & styles, build a simple interactive command line tool or a complexe terminal application: this is the absolute terminal lib for Node.js!

It does NOT depend on ncurses.

Some tutorials are available at blog.soulserv.net/tag/terminal.

Screenshot, PleaZe!

This is a fraction of what Terminal-Kit can do, with only few lines of code. Click any image to see the documentation related to the feature!

Styles output

Word-wrapping ← Word-wrapping

Table ← Table with automatic column computing, cell fitting and word-wrapping

Input field output

File input output

Input field output

Single line menu output

Single column menu output

Grid menu output

Progress bar output

Progress bar output

Slow typing output

Yes or no output

Spaceship ← Surfaces and Sprites

Draw an image inside the terminal ← Load and draw an image inside the terminal

Key features

New: Document model for building rich app GUI

New: Spinner

New: Table with automatic column computing, cell fitting and word-wrapping

New: Promises can be used instead of callback everywhere

New: Word-wrapping along full terminal width or a pre-defined column-width

New: ScreenBuffer HD 32-bit (RGBA) surfaces with composition and image loading

Quick examples

// Require the lib, get a working terminal
var term = require( 'terminal-kit' ).terminal ;

// The term() function simply output a string to stdout, using current style
// output "Hello world!" in default terminal's colors
term( 'Hello world!\n' ) ;

// This output 'red' in red
term.red( 'red' ) ;

// This output 'bold' in bold
term.bold( 'bold' ) ;

// output 'mixed' using bold, underlined & red, exposing the style-mixing syntax
term.bold.underline.red( 'mixed' ) ;

// printf() style formatting everywhere:
// this will output 'My name is Jack, I'm 32.' in green
term.green( "My name is %s, I'm %d.\n" , 'Jack' , 32 ) ;

// Since v0.16.x, style markup are supported as a shorthand.
// Those two lines produce the same result.
term( "My name is " ).red( "Jack" )( " and I'm " ).green( "32\n" ) ;
term( "My name is ^rJack^ and I'm ^g32\n" ) ;

// Width and height of the terminal
term( 'The terminal size is %dx%d' , term.width , term.height ) ;

// Move the cursor at the upper-left corner
term.moveTo( 1 , 1 ) ;

// We can always pass additional arguments that will be displayed...
term.moveTo( 1 , 1 , 'Upper-left corner' ) ;

// ... and formated
term.moveTo( 1 , 1 , "My name is %s, I'm %d.\n" , 'Jack' , 32 ) ;

// ... or even combined with other styles
term.moveTo.cyan( 1 , 1 , "My name is %s, I'm %d.\n" , 'Jack' , 32  ) ;

// Get some user input
term.magenta( "Enter your name: " ) ;
term.inputField(
	function( error , input ) {
		term.green( "\nYour name is '%s'\n" , input ) ;
	}
) ;

♥♥ I want to READ THE DOC NOW! ♥♥

License: MIT

3.1.1

10 months ago

3.1.0

10 months ago

3.0.2

10 months ago

3.0.1

1 year ago

2.11.0

2 years ago

2.11.1

2 years ago

2.11.6

2 years ago

2.11.7

2 years ago

2.11.4

2 years ago

2.11.5

2 years ago

2.11.2

2 years ago

2.11.3

2 years ago

2.10.1

2 years ago

2.10.2

2 years ago

2.10.0

2 years ago

2.10.5

2 years ago

2.10.6

2 years ago

2.10.3

2 years ago

2.10.4

2 years ago

3.0.0

2 years ago

2.8.1

2 years ago

2.8.0

2 years ago

2.9.2

2 years ago

2.9.1

2 years ago

2.9.4

2 years ago

2.9.3

2 years ago

2.9.6

2 years ago

2.9.5

2 years ago

2.9.8

2 years ago

2.9.7

2 years ago

2.7.0

2 years ago

2.8.3

2 years ago

2.8.2

2 years ago

2.8.5

2 years ago

2.8.4

2 years ago

2.8.7

2 years ago

2.8.6

2 years ago

2.8.9

2 years ago

2.8.8

2 years ago

2.6.0

2 years ago

2.9.0

2 years ago

2.8.12

2 years ago

2.8.11

2 years ago

2.8.10

2 years ago

2.5.0

2 years ago

2.5.1

2 years ago

2.4.0

3 years ago

2.3.0

3 years ago

2.2.4

3 years ago

2.2.1

3 years ago

2.2.0

3 years ago

2.2.3

3 years ago

2.2.2

3 years ago

2.1.8

3 years ago

2.1.7

3 years ago

1.49.4

3 years ago

2.1.6

3 years ago

2.1.4

4 years ago

2.1.5

4 years ago

2.1.2

4 years ago

2.1.1

4 years ago

2.1.3

4 years ago

2.1.0

4 years ago

2.0.7

4 years ago

2.0.6

4 years ago

2.0.5

4 years ago

2.0.4

4 years ago

2.0.3

4 years ago

2.0.2

4 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.49.3

4 years ago

1.49.1

4 years ago

1.49.0

4 years ago

1.49.2

4 years ago

1.48.1

4 years ago

1.47.1

4 years ago

1.47.2

4 years ago

1.48.0

4 years ago

1.47.0

4 years ago

1.46.0

4 years ago

1.46.1

4 years ago

1.45.7

4 years ago

1.45.9

4 years ago

1.45.8

4 years ago

1.45.5

4 years ago

1.45.4

4 years ago

1.45.3

4 years ago

1.45.1

4 years ago

1.45.0

4 years ago

1.45.2

4 years ago

1.44.1

4 years ago

1.44.3

4 years ago

1.44.0

4 years ago

1.43.0

4 years ago

1.42.0

4 years ago

1.41.0

4 years ago

1.40.0

4 years ago

1.37.0

4 years ago

1.38.0

4 years ago

1.39.0

4 years ago

1.36.0

4 years ago

1.35.13

4 years ago

1.35.12

4 years ago

1.35.11

4 years ago

1.35.10

4 years ago

1.35.9

4 years ago

1.35.8

5 years ago

1.35.6

5 years ago

1.35.7

5 years ago

1.35.5

5 years ago

1.35.4

5 years ago

1.35.3

5 years ago

1.35.2

5 years ago

1.35.1

5 years ago

1.35.0

5 years ago

1.34.5

5 years ago

1.34.4

5 years ago

1.34.3

5 years ago

1.34.2

5 years ago

1.34.1

5 years ago

1.34.0

5 years ago

1.33.11

5 years ago

1.33.13

5 years ago

1.33.12

5 years ago

1.33.15

5 years ago

1.33.14

5 years ago

1.33.10

5 years ago

1.33.9

5 years ago

1.33.8

5 years ago

1.33.7

5 years ago

1.33.6

5 years ago

1.33.5

5 years ago

1.33.3

5 years ago

1.33.4

5 years ago

1.33.2

5 years ago

1.33.1

5 years ago

1.33.0

5 years ago

1.32.3

5 years ago

1.32.2

5 years ago

1.32.1

5 years ago

1.32.0

5 years ago

1.31.10

5 years ago

1.31.9

5 years ago

1.31.8

5 years ago

1.31.7

5 years ago

1.31.6

5 years ago

1.31.5

5 years ago

1.31.4

5 years ago

1.31.3

5 years ago

1.31.2

5 years ago

1.31.1

5 years ago

1.31.0

5 years ago

1.30.0

5 years ago

1.29.3

5 years ago

1.29.2

5 years ago

1.29.1

5 years ago

1.29.0

5 years ago

1.28.42

5 years ago

1.28.41

5 years ago

1.28.40

5 years ago

1.28.39

5 years ago

1.28.38

5 years ago

1.28.37

5 years ago

1.28.36

5 years ago

1.28.35

5 years ago

1.28.34

5 years ago

1.28.33

5 years ago

1.28.32

5 years ago

1.28.31

5 years ago

1.28.30

5 years ago

1.28.29

5 years ago

1.28.28

5 years ago

1.28.27

5 years ago

1.28.26

5 years ago

1.28.25

5 years ago

1.28.24

5 years ago

1.28.23

5 years ago

1.28.22

5 years ago

1.28.21

5 years ago

1.28.20

5 years ago

1.28.19

5 years ago

1.28.18

5 years ago

1.28.17

5 years ago

1.28.16

5 years ago

1.28.15

5 years ago

1.28.14

5 years ago

1.28.13

5 years ago

1.28.12

5 years ago

1.28.11

5 years ago

1.28.10

5 years ago

1.28.9

5 years ago

1.28.8

5 years ago

1.28.7

5 years ago

1.28.6

5 years ago

1.28.5

5 years ago

1.28.4

5 years ago

1.28.3

5 years ago

1.28.2

6 years ago

1.28.1

6 years ago

1.28.0

6 years ago

1.27.3

6 years ago

1.27.2

6 years ago

1.27.1

6 years ago

1.27.0

6 years ago

1.26.11

6 years ago

1.26.10

6 years ago

1.26.9

6 years ago

1.26.8

6 years ago

1.26.7

6 years ago

1.26.6

6 years ago

1.26.5

6 years ago

1.26.4

6 years ago

1.26.3

6 years ago

1.26.2

6 years ago

1.26.1

6 years ago

1.26.0

6 years ago

1.25.0

6 years ago

1.24.1

6 years ago

1.24.0

6 years ago

1.23.0

6 years ago

1.22.1

6 years ago

1.22.0

6 years ago

1.21.0

6 years ago

1.20.0

6 years ago

1.19.2

6 years ago

1.19.1

6 years ago

1.19.0

6 years ago

1.18.0

6 years ago

1.17.13

6 years ago

1.17.12

6 years ago

1.17.11

7 years ago

1.17.10

7 years ago

1.17.9

7 years ago

1.17.8

7 years ago

1.17.7

7 years ago

1.17.6

7 years ago

1.17.5

7 years ago

1.17.4

7 years ago

1.17.3

7 years ago

1.17.2

7 years ago

1.17.1

7 years ago

1.17.0

7 years ago

1.16.1

7 years ago

1.16.0

7 years ago

1.15.6

7 years ago

1.15.5

7 years ago

1.15.4

7 years ago

1.15.3

7 years ago

1.15.2

7 years ago

1.15.1

7 years ago

1.15.0

7 years ago

1.14.3

7 years ago

1.14.2

7 years ago

1.14.1

7 years ago

1.14.0

7 years ago

1.13.13

7 years ago

1.13.12

7 years ago

1.13.11

7 years ago

1.13.10

7 years ago

1.13.9

7 years ago

1.13.8

7 years ago

1.13.7

7 years ago

1.13.6

7 years ago

1.13.5

7 years ago

1.13.4

7 years ago

1.13.3

7 years ago

1.13.2

7 years ago

1.13.1

7 years ago

1.13.0

7 years ago

1.12.3

7 years ago

1.12.2

7 years ago

1.12.1

7 years ago

1.12.0

7 years ago

1.11.2

7 years ago

1.11.1

7 years ago

1.11.0

8 years ago

1.10.2

8 years ago

1.10.1

8 years ago

1.10.0

8 years ago

1.9.0

8 years ago

1.8.13

8 years ago

1.8.12

8 years ago

1.8.11

8 years ago

1.8.10

8 years ago

1.8.8

8 years ago

1.8.9

8 years ago

1.8.7

8 years ago

1.8.6

8 years ago

1.8.5

8 years ago

1.8.4

8 years ago

1.8.3

8 years ago

1.8.2

8 years ago

1.8.1

8 years ago

1.8.0

8 years ago

1.7.2

8 years ago

1.7.1

8 years ago

1.7.0

8 years ago

1.6.8

8 years ago

1.6.7

8 years ago

1.6.6

8 years ago

1.6.5

8 years ago

1.6.4

8 years ago

1.6.3

8 years ago

1.6.2

8 years ago

1.6.1

8 years ago

1.6.0

8 years ago

1.5.4

8 years ago

1.5.3

8 years ago

1.5.2

8 years ago

1.5.1

8 years ago

1.5.0

8 years ago

1.4.4

8 years ago

1.4.3

8 years ago

1.4.2

8 years ago

1.4.1

8 years ago

1.4.0

8 years ago

1.3.0

8 years ago

1.2.12

8 years ago

1.2.11

8 years ago

1.2.10

8 years ago

1.2.9

8 years ago

1.2.8

8 years ago

1.2.7

8 years ago

1.2.6

8 years ago

1.2.5

8 years ago

1.2.4

8 years ago

1.2.3

8 years ago

1.2.2

8 years ago

1.2.1

8 years ago

1.2.0

8 years ago

1.1.5

8 years ago

1.1.4

8 years ago

1.1.3

8 years ago

1.1.2

8 years ago

1.1.1

8 years ago

1.1.0

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago

0.30.7

8 years ago

0.30.6

8 years ago

0.30.5

8 years ago

0.30.4

8 years ago

0.30.3

8 years ago

0.30.2

8 years ago

0.30.1

8 years ago

0.30.0

8 years ago

0.29.0

8 years ago

0.28.4

8 years ago

0.28.3

8 years ago

0.28.2

8 years ago

0.28.1

8 years ago

0.28.0

8 years ago

0.27.4

8 years ago

0.27.3

8 years ago

0.27.2

8 years ago

0.27.1

8 years ago

0.27.0

8 years ago

0.26.2

8 years ago

0.26.1

8 years ago

0.26.0

8 years ago

0.25.6

8 years ago

0.25.5

8 years ago

0.25.4

8 years ago

0.25.3

8 years ago

0.25.2

8 years ago

0.25.1

8 years ago

0.25.0

8 years ago

0.24.30

8 years ago

0.24.29

8 years ago

0.24.28

8 years ago

0.24.27

8 years ago

0.24.26

8 years ago

0.24.25

8 years ago

0.24.24

8 years ago

0.24.23

8 years ago

0.24.22

8 years ago

0.24.21

8 years ago

0.24.20

8 years ago

0.24.19

8 years ago

0.24.18

8 years ago

0.24.17

8 years ago

0.24.16

8 years ago

0.24.15

8 years ago

0.24.14

8 years ago

0.24.13

8 years ago

0.24.12

8 years ago

0.24.11

8 years ago

0.24.10

8 years ago

0.24.9

9 years ago

0.24.8

9 years ago

0.24.7

9 years ago

0.24.6

9 years ago

0.24.5

9 years ago

0.24.4

9 years ago

0.24.3

9 years ago

0.24.2

9 years ago

0.24.1

9 years ago

0.24.0

9 years ago

0.23.1

9 years ago

0.23.0

9 years ago

0.22.7

9 years ago

0.22.6

9 years ago

0.22.5

9 years ago

0.22.4

9 years ago

0.22.3

9 years ago

0.22.2

9 years ago

0.22.1

9 years ago

0.22.0

9 years ago

0.21.8

9 years ago

0.21.7

9 years ago

0.21.6

9 years ago

0.21.5

9 years ago

0.21.4

9 years ago

0.21.3

9 years ago

0.21.2

9 years ago

0.21.1

9 years ago

0.21.0

9 years ago

0.20.32

9 years ago

0.20.30

9 years ago

0.20.31

9 years ago

0.20.29

9 years ago

0.20.28

9 years ago

0.20.27

9 years ago

0.20.26

9 years ago

0.20.25

9 years ago

0.20.23

9 years ago

0.20.24

9 years ago

0.20.22

9 years ago

0.20.21

9 years ago

0.20.20

9 years ago

0.20.19

9 years ago

0.20.18

9 years ago

0.20.17

9 years ago

0.20.16

9 years ago

0.20.14

9 years ago

0.20.13

9 years ago

0.20.12

9 years ago

0.20.11

9 years ago

0.20.10

9 years ago

0.20.9

9 years ago

0.20.8

9 years ago

0.20.7

9 years ago

0.20.6

9 years ago

0.20.5

9 years ago

0.20.4

9 years ago

0.20.3

9 years ago

0.20.2

9 years ago

0.20.1

9 years ago

0.20.0

9 years ago

0.19.4

9 years ago

0.19.3

9 years ago

0.19.2

9 years ago

0.19.1

9 years ago

0.19.0

9 years ago

0.18.0

9 years ago

0.17.0

9 years ago

0.16.14

9 years ago

0.16.13

9 years ago

0.16.12

9 years ago

0.16.11

9 years ago

0.16.10

9 years ago

0.16.9

9 years ago

0.16.8

9 years ago

0.16.7

9 years ago

0.16.6

9 years ago

0.16.5

9 years ago

0.16.4

9 years ago

0.16.3

9 years ago

0.16.2

9 years ago

0.16.1

9 years ago

0.16.0

9 years ago

0.15.12

9 years ago

0.15.11

9 years ago

0.15.10

9 years ago

0.15.9

9 years ago

0.15.8

9 years ago

0.15.7

9 years ago

0.15.6

9 years ago

0.15.5

9 years ago

0.15.4

9 years ago

0.15.3

9 years ago

0.15.2

9 years ago

0.15.1

9 years ago

0.15.0

9 years ago

0.14.10

9 years ago

0.14.9

9 years ago

0.14.8

9 years ago

0.14.7

9 years ago

0.14.6

9 years ago

0.14.5

9 years ago

0.14.4

9 years ago

0.14.3

9 years ago

0.14.2

9 years ago

0.14.1

9 years ago

0.14.0

10 years ago

0.13.16

10 years ago

0.13.15

10 years ago

0.13.14

10 years ago

0.13.13

10 years ago

0.13.12

10 years ago

0.13.11

10 years ago

0.13.10

10 years ago

0.13.9

10 years ago

0.13.8

10 years ago

0.13.7

10 years ago

0.13.6

10 years ago

0.13.5

10 years ago

0.13.4

10 years ago

0.13.3

10 years ago

0.13.2

10 years ago

0.13.1

10 years ago

0.12.8

10 years ago

0.12.7

10 years ago

0.12.6

10 years ago

0.12.5

10 years ago

0.12.4

10 years ago

0.12.3

10 years ago

0.12.2

10 years ago

0.12.1

10 years ago

0.12.0

10 years ago

0.11.3

10 years ago

0.11.2

10 years ago

0.11.1

10 years ago

0.11.0

10 years ago

0.10.9

10 years ago

0.10.8

10 years ago

0.10.7

10 years ago

0.10.6

10 years ago

0.10.5

10 years ago

0.10.4

10 years ago

0.10.3

10 years ago

0.10.2

10 years ago

0.10.1

10 years ago

0.10.0

10 years ago

0.9.14

10 years ago

0.9.13

10 years ago

0.9.12

10 years ago

0.9.11

10 years ago

0.9.10

10 years ago

0.9.9

10 years ago

0.9.8

10 years ago

0.9.7

10 years ago

0.9.6

10 years ago

0.9.5

10 years ago

0.9.4

10 years ago

0.9.3

10 years ago

0.9.2

10 years ago

0.9.1

10 years ago

0.9.0

10 years ago

0.8.0

10 years ago

0.7.1

10 years ago

0.7.0

10 years ago

0.6.14

10 years ago

0.6.13

10 years ago

0.6.12

10 years ago

0.6.11

10 years ago

0.6.10

10 years ago

0.6.9

10 years ago

0.6.8

10 years ago

0.6.7

10 years ago

0.6.6

10 years ago

0.6.5

10 years ago

0.6.4

10 years ago

0.6.3

10 years ago

0.6.2

10 years ago

0.6.1

10 years ago

0.6.0

10 years ago

0.5.18

10 years ago

0.5.17

10 years ago

0.5.16

10 years ago

0.5.15

10 years ago

0.5.14

10 years ago

0.5.13

10 years ago

0.5.12

10 years ago

0.5.11

10 years ago

0.5.10

10 years ago

0.5.9

10 years ago

0.5.8

10 years ago

0.5.7

10 years ago

0.5.6

10 years ago

0.5.5

10 years ago

0.5.4

10 years ago

0.5.3

10 years ago

0.5.2

10 years ago

0.5.1

10 years ago

0.4.5

10 years ago

0.4.4

10 years ago

0.4.3

10 years ago

0.4.2

10 years ago

0.4.1

10 years ago

0.4.0

10 years ago

0.3.9

10 years ago

0.3.8

10 years ago

0.3.7

10 years ago

0.3.5

10 years ago

0.3.4

10 years ago

0.3.3

10 years ago

0.3.2

10 years ago

0.3.1

10 years ago

0.2.4

10 years ago

0.2.3

10 years ago

0.2.2

10 years ago

0.2.1

10 years ago

0.1.28

10 years ago

0.1.27

10 years ago

0.1.25

10 years ago

0.1.24

10 years ago

0.1.23

10 years ago

0.1.22

10 years ago

0.1.21

10 years ago

0.1.20

10 years ago

0.1.19

10 years ago

0.1.18

10 years ago

0.1.17

10 years ago

0.1.16

10 years ago

0.1.15

10 years ago

0.1.14

10 years ago

0.1.13

10 years ago

0.1.12

10 years ago

0.1.11

10 years ago

0.1.10

10 years ago

0.1.9

10 years ago

0.1.8

10 years ago

0.1.7

10 years ago

0.1.6

10 years ago

0.1.5

10 years ago

0.1.4

10 years ago

0.1.3

10 years ago

0.1.2

10 years ago

0.1.1

10 years ago

0.0.8

10 years ago

0.0.7

10 years ago

0.0.6

10 years ago

0.0.5

10 years ago