cd-messenger
console log logger gulp notification browser node message
Last updated 2 years ago by codedungeon .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install cd-messenger 
SYNC missed versions from official npm registry.

cd-messenger

Node and Browser Messages

Use same API across browser or node and cd-messenger will handle the rest for you!

View on npm

Install with npm

npm i -S cd-messenger

Install with yarn

yarn add cd-messenger

Add as script tag

<script src="lib/messenger.min.js"></script>

Usage

const msg = require('cd-messenger');

// You can use titleCase or lower case for msg methods
// assuming `name` variable has been set to value before calling below

let name = 'Mike Erickson';

=========================================================================================
msg.info    ('Loading...');
msg.log     (`name: ${name}`);  // default color White
msg.info    (`name: ${name}`);  // default color Cyan
msg.success (`name: ${name}`);  // default color Green
msg.warning (`name: ${name}`);  // default color Yellow
msg.error   (`name: ${name}`);  // default color Red
msg.note    (`name: ${name}`);  // default color Orange
msg.debug   (`name: ${name}`);  // default color white
msg.table   (array|object)      // uses console.table (browser) or nice cli table (node)

=========================================================================================
msg.line(...)
msg.line  // displays a colored line (you can define line character, color, and width)
msg.line    ('', 'magenta');    // displays a line with solid magenta (no char)
msg.line    ('•', 'green');     // displays a line with repeating '•' and green
msg.line    ('', 'yellow', 40); // display with repeating (40) box, yellow

=========================================================================================
msg.setOptions(options: object)     // customize default browser appearance
 option.logger (true|false:default) // try it out and see how it looks

License

Copyright © 2016-2017 Mike Erickson Released under the MIT license

Credits

cd-messenger written by Mike Erickson

E-Mail: codedungeon@gmail.com

Twitter: @codedungeon

Webiste: codedungeon.org


Current Tags

  • 2.7.26                                ...           latest (2 years ago)
  • 2.2.1-build.24                                ...           next (4 years ago)

62 Versions

  • 2.7.26                                ...           2 years ago
  • 2.7.24                                ...           4 years ago
  • 2.7.23                                ...           4 years ago
  • 2.7.22                                ...           4 years ago
  • 2.7.21                                ...           4 years ago
  • 2.7.20                                ...           4 years ago
  • 2.7.19                                ...           4 years ago
  • 2.7.17                                ...           4 years ago
  • 2.7.16                                ...           4 years ago
  • 2.7.14                                ...           4 years ago
  • 2.7.12                                ...           4 years ago
  • 2.7.11                                ...           4 years ago
  • 2.7.10                                ...           4 years ago
  • 2.7.9                                ...           4 years ago
  • 2.7.8                                ...           4 years ago
  • 2.7.7                                ...           4 years ago
  • 2.7.6                                ...           4 years ago
  • 2.7.5                                ...           4 years ago
  • 2.7.4                                ...           4 years ago
  • 2.7.3                                ...           4 years ago
  • 2.7.2                                ...           4 years ago
  • 2.7.1                                ...           4 years ago
  • 2.7.0                                ...           4 years ago
  • 2.6.1                                ...           4 years ago
  • 2.6.0                                ...           4 years ago
  • 2.5.2                                ...           4 years ago
  • 2.5.1                                ...           4 years ago
  • 2.5.0                                ...           4 years ago
  • 2.4.1                                ...           4 years ago
  • 2.3.5                                ...           4 years ago
  • 2.3.3                                ...           4 years ago
  • 2.3.2                                ...           4 years ago
  • 2.3.1                                ...           4 years ago
  • 2.3.0                                ...           4 years ago
  • 2.2.3                                ...           4 years ago
  • 2.2.2                                ...           4 years ago
  • 2.2.1                                ...           4 years ago
  • 2.2.1-build.24                                ...           4 years ago
  • 2.2.1-build.7                                ...           4 years ago
  • 2.2.0                                ...           4 years ago
  • 2.1.1                                ...           4 years ago
  • 2.1.0                                ...           4 years ago
  • 2.0.6                                ...           4 years ago
  • 2.0.5                                ...           4 years ago
  • 2.0.3                                ...           4 years ago
  • 2.0.1                                ...           4 years ago
  • 2.0.0-build.219                                ...           4 years ago
  • 2.0.0-build.217                                ...           4 years ago
  • 2.0.0-build.210                                ...           4 years ago
  • 2.0.0-build.209                                ...           4 years ago
  • 2.0.0-build.208                                ...           4 years ago
  • 2.0.0-build.207                                ...           4 years ago
  • 2.0.0-build.204                                ...           4 years ago
  • 2.0.0-build.203                                ...           4 years ago
  • 2.0.0-build.187                                ...           4 years ago
  • 2.0.0-build.181                                ...           4 years ago
  • 2.0.0-build.180                                ...           4 years ago
  • 2.0.0-build.163                                ...           4 years ago
  • 2.0.0-build.161                                ...           4 years ago
  • 2.0.0-build.160                                ...           4 years ago
  • 2.0.0-build.155                                ...           4 years ago
  • 2.0.0                                ...           4 years ago
Downloads
Today 0
This Week 0
This Month 1
Last Day 0
Last Week 0
Last Month 1
Dependencies (4)
Dependents (1)

Copyright 2014 - 2016 © taobao.org |