1.3.1 • Published 5 years ago
@emersonbraun/pretty-log v1.3.1
Pretty Log
Get beautiful consoles easily
Prerequisites
Installing
Using NPM
npm i @emersonbraun/pretty-logOR Yarn
yarn add @emersonbraun/pretty-logUsage
import package
import PrettyLog from '@emersonbraun/pretty-log' //es6
var PrettyLog = require('@emersonbraun/pretty-log').default // old form Type Info
PrettyLog.info('test info')Output: 
Type Info (with var)
const hello = 'hello word'
PrettyLog.info('test info', hello)Output: 
Type success
PrettyLog.success('teste success')Output: 
Type success (with var)
const hello = 'hello word'
PrettyLog.success('teste success', hello)Output: 
Type warn
PrettyLog.warn('teste warn')Output: 
Type warn (with var)
const hello = 'hello word'
PrettyLog.warn('teste warn', hello)Output: 
Type error
PrettyLog.error('teste error')Output: 
Type error (with var)
const hello = 'hello word'
PrettyLog.error('teste error', hello)Output: 
Type custom
pass options
| Name | Value | Obs |
|---|---|---|
| icon | 'cross', 'tick', ... | Options in figures |
| iconColor | 'red', 'blue', ... | Options in chalk |
| title | string | Any text |
| titleColor | 'red', 'blue', ... | Options in chalk |
PrettyLog.custom('teste custom', null, {
iconColor: 'white',
icon: 'bullet',
})Output

Type custom (with var)
const hello = 'hello word'
PrettyLog.custom('teste custom', hello, {
iconColor: 'white',
icon: 'bullet',
})Output:
Versioning
We use SemVer for versioning. For the versions available, see the tags on this repository.
Author
- emersonbraun - Initial work - EmersonBraun
See also the list of contributors who participated in this project.
License
This project is licensed under the MIT License - see the LICENSE.md file for details