@kalimahapps/cli-progress
TypeScript icon, indicating that this package has built-in type declarations

1.0.4 • Public • Published

Cli Progress

This is a wrapper around cli-progress package with personal preferences.

Installation

pnpm install @kalimahapps/cli-progress

Usage

import { createProgressBar, createHeader } from '@kalimahapps/cli-progress';

// Create a header
createHeader('Header');

// Create a progress bar
const progress = createProgressBar('Downloading');
for (let index = 0; index <= 100; index++) {
	await new Promise((resolve) => {
		return setTimeout(resolve, 10);
	});
	progress.update(index);
}
progress.stop();

API

createHeader

Creates a header with a title.

Parameters

  • title: string: The title of the header.

createProgressBar

Creates a progress bar.

Parameters

  • prefix?: string: Content to display before the progress bar.

Package Sidebar

Install

npm i @kalimahapps/cli-progress

Weekly Downloads

4

Version

1.0.4

License

MIT

Unpacked Size

3.71 kB

Total Files

4

Last publish

Collaborators

  • khr2003