1.0.3 • Published 3 years ago

cli-alert v1.0.3

Weekly downloads
3
License
MIT
Repository
github
Last release
3 years ago

cli-alert screenshot

cli-alerts

DOWNLOADS Learn VSCode Follow @tkoriginale on Twitter

Cross Platform CLI Alerts

📟

Install

npm install cli-alert

⚙️

Usage

const alert = require('cli-alert')

// You can choose between SUCCESS, INFO, WARNING, ERROR

alert()
// Prints: ✖  ERROR  You forgot to define all options

alert({ type: 'success', msg: 'All Done!', name: 'Great' })
// Prints:  ✔  GREAT  All Done!

alert({ type: 'info', msg: 'This is a cool package' })
// Prints:  ℹ  INFO  This is a cool package

alert({ type: 'warning', msg: "You didn't add something!" })
// Prints:  ⚠  WARNING  You didn't add something!

alert({ type: 'error', msg: 'Something went wrong mate' })
// Prints:  ✖  ERROR  Something went wrong mate

📃

API

alert(options)

❯ options

Type: object Default: {}

❯ type

Type: string Default: error

❯ msg

Type: string Default: You forgot to define all options

❯ name

Type: string Default:

📝

Changelog

❯ Read the changelog here →

KEY: 📦 NEW, 👌 IMPROVE, 🐛 FIX, 📖 DOC, 🚀 RELEASE, and ✅ TEST

I use Emoji-log, you should try it and simplify your git commits.

📃

License & Conduct

🙌

  • This readme was build using template and icons from Ahmad Awais