A very simple console progress bar for Node.JS
npm install simple-progress-bar
simple-progress-bar
===================
A console progress bar that is easy to use and understand.
###Constructor:
var progressbar = new ProgressBar(labelText, formatString, writeableStream);
1. labelText: string (Default: Progress) The value of the label next to the progress bar.
2. formatString: string (Default: :label :bar :percent) The string containing format elements to be replaced on update.
1. :label replaced with the labelText value.
2. :bar replaced with the progress bar.
3. :percent replaced with the current progress percent.
3. writeableStream: obj (Default: stdout) The writable stream the progressbar will be written to.
###Example Usage:
``
`
var ProgressBar = require('simple-progrss-bar'),
pb;
globals.pubsub.on('event', (itemCount, totalItems) => {
pb = pb || new ProgressBar('Progress: ', ':label \t [ :bar ] :percent ');
pb.update(itemCount, totalItems);
});
update(itemCount, totalItems)
###Methods:
: updates the progress bar to the percent calculated by the itemCount divided by the totalItems value.
grunt` This will build the package manually.
###Building:
####Built with TypeScript.