consome
v1.0.1
Published
add a console.logAt function to your NodeJS console
Downloads
6
Readme
Consome = Console + Awesome :raised_hands:
Add a logAt(index, message) function to your NodeJS console.
Install
yarn add -D consome
or
npm i -save-dev consome
Basic Usage
require('consome');
console.logAt(0, 'logging something at line 0');
console.logAt(2, 'logging something at line 2');
Demo
Let's implement a dynamic terminal loader:
require('consome');
console.log('----- Demo -----');
const loadingLine = console.log('Loading');
setInterval(() => {
console.logAt(loadingLine, `Loading ${loader.next()}`)
}, 500);
console.log('----- Fin -----');
Result
License
Unless otherwise specified this project is licensed under Apache License Version 2.0.