dbot-console-logger
TypeScript icon, indicating that this package has built-in type declarations

1.1.1 • Public • Published

Discord Bot Console Logger

Custom formatted console logs designed to be used in Discord bots!

Demo!

Default logs

Without spacing

Logs with spacing enabled

With spacing

After installing run npm run test for a full test and demo.

Installation

To install simply run npm install dbot-console-logger

Then require with const log = require('dbot-console-logger');.

Settings such as changing the time, timestamp format, logging colors and more can be found in the config.js file.

Usage

log.error("text", "inspect (optional))

Logs errors to the console. Aliases: e, err

log.warn("text", "inspect (optional))

Logs errors to the console. Aliases: w, warning

log.info("text", "inspect (optional))

Logs errors to the console. Aliases: i, information

log.debug("text", "inspect (optional))

Logs errors to the console. Aliases: d, db, bug

log.timestamp()

Logs a timestamp to the console. Aliases: t, ts, time

log.chalk(options)

Passes chalk though. Learn more at https://www.npmjs.com/package/chalk. Aliases: c

log.moment(options)

Passes moment.js though. Learn more at https://momentjs.com/docs/. Aliases: m

Support

If you need help or assistance please either ask in my Discord server or create a new issue.

Readme

Keywords

Package Sidebar

Install

npm i dbot-console-logger

Weekly Downloads

6

Version

1.1.1

License

MIT

Unpacked Size

10.4 kB

Total Files

7

Last publish

Collaborators

  • gideon_foxo