# loggaby

> 📝 A simple, lightweight and customizable logger.

Latest version **4.0.3** (published 2021-02-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install loggaby
pnpm add loggaby
yarn add loggaby
bun add loggaby
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 4.0.3 |
| Published | 2021-02-19 |
| First published | 2020-07-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 12.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Luvella |
| Maintainers | samuraistacks |
| Keywords | color, colors, console, logger, log, terminal |

## Links

- npm: https://www.npmjs.com/package/loggaby
- Repository: https://github.com/Loggaby/Loggaby
- Homepage: https://github.com/Loggaby/Loggaby#readme
- Issues: https://github.com/Loggaby/Loggaby/issues
- npm.io page: https://npm.io/package/loggaby

## Dependencies (1)

- [ansikit](https://npm.io/package/ansikit.md) ^1.5.0

## Recent versions

- 4.0.3 (latest) — 2021-02-19
- 4.0.2 — 2021-02-10
- 4.0.1 — 2020-12-17
- 4.0.0 — 2020-11-08
- 3.0.1 — 2020-10-19
- 3.0.0 — 2020-10-17
- 2.2.0 — 2020-10-04
- 2.1.0 — 2020-09-30
- 2.0.0 — 2020-09-22
- 1.0.1 — 2020-07-15
- 1.0.0 — 2020-07-12

## README

<div align="center">
	<h1>Loggaby</h1>
	<blockquote align="center">📝 A simple, lightweight and customizable logger.</blockquote>
	<p>
		<a href="https://github.com/Loggaby/Loggaby/blob/master/LICENSE">
			<img alt="GitHub license" src="https://img.shields.io/github/license/Loggaby/Loggaby?style=for-the-badge">
		</a>
		<a href="https://github.com/Loggaby/Loggaby/stargazers">
			<img alt="GitHub stars" src="https://img.shields.io/github/stars/Loggaby/Loggaby?style=for-the-badge">
		</a>
		<br>
		Loggaby is the simple, lightweight and minimal logger.
		<br>
		It has 1 goal and strives for it well: Posting nice looking logs to your terminal (or wherever you want, see <a href="#examples">the examples</a> for details)
		<br><br>
		<img alt="Preview" src="https://modeus.is-inside.me/sK6rnRGq.png">
		<br>
		<i>How it looks for default.</i>
		<br><br>
		PS: It's also customizable (highly so)! From how it looks, to the log destination.<br>
		<img alt="Preview" src="https://modeus.is-inside.me/rV5DHbxa.png" href="/examples/logFormat.js">
	</p>
</div>

# Table of Contents
- [Install](#install)
- [Examples](#examples)
- [Docs](#documentation)
- [License](#license) 

## Install
`npm install loggaby`

Or with Yarn:  
`yarn add loggaby`

## Examples
[Provided Here](examples/).

# Documentation
#### new Loggaby(options) 
The Loggaby constructor, which creates a new `Loggaby` instance.
- `options` {Object}
  - `debug` {Boolean | String} Whether to print debug messages. Can be a boolean or `'auto'`. (Default: `true`)
  - `format` {String} Format for how logs should look (Default: `'{grey}{time}{reset} {level} > '`)
  - `levels` {Object[]} Additional custom levels to provide.
    - `name` {String} Name of the level that appears in the logs.
    - `color` {String} Color of the level name. Accepted values are a hex value or [named colors](https://github.com/Luvella/AnsiKit#colors).
    - `debug` {Boolean} Whether this level will be hidden when `options.debug` is false.
    - `fatal` {Boolean} Whether to make the level name and message bold and underline (to be noticeable).
    - `call` {String} Name of the function to use this level.
  - `transports` {Object[]} (An array of objects or specifically [transport instances](lib/transports/)) What transports to log to.  An example is provided above. (Default: `[TerminalTransport]`)

## Default Levels
`debug`, `log`, `warn`, `error` and `fatal`  
You can log with `Loggaby.<Level>()`.

# License
Loggaby is licensed under the MIT license.  
[Read here](LICENSE) for more info.

<hr>
<p align="center">
	<i>A <a href="https://github.com/Luvella">Luvella</a> project.</i>
	<br>
	<img src="https://modeus.is-inside.me/ZvFTbWcA.png" width=52>
</p>

---
_Source: https://npm.io/package/loggaby · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
