Socket
Book a DemoInstallSign in
Socket

etz

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

etz

A humble logger.

latest
Source
npmnpm
Version
3.0.0
Version published
Maintainers
1
Created
Source

etz

version CI gzip size brotli size Sponsor
A humble logger.

Features

  • Humble: it just prints pretty filterable logs to the console!
  • Filtering: use ETZ and NO_ETZ environment variables to filter
  • Cool Name: just three letters transliterated from Hebrew

Install

$ npm i etz

Usage

index.js:

import etz from 'etz'

etz.debug(`Hello World!`)
etz.info(`Hello World!`)
etz.warn(`Hello World!`)
etz.error(`Hello World!`)

Log level

NOTE: The examples below are not colorized, but they will be in your terminal!

The default log level is INFO:

$ node index.js
ℹ INFO Hello World!
⚠ WARN Hello World!
✖ ERROR Hello World!

Set the log level with the ETZ environment variable:

$ node index.js
ℹ INFO Hello World!
⚠ WARN Hello World!
✖ ERROR Hello World!

$ ETZ=0 node index.js
★ DEBUG Hello World!
ℹ INFO Hello World!
⚠ WARN Hello World!
✖ ERROR Hello World!

$ ETZ=debug node index.js
★ DEBUG Hello World!
ℹ INFO Hello World!
⚠ WARN Hello World!
✖ ERROR Hello World!

$ ETZ=3 node index.js
★ DEBUG Hello World!
ℹ INFO Hello World!
⚠ WARN Hello World!
✖ ERROR Hello World!

$ ETZ=error node index.js
✖ ERROR Hello World!

Suppress all logs with NO_ETZ:

$ NO_ETZ=1 node index.js

The value of NO_ETZ doesn't matter. Any value works.

FAQ

What's with the name?

The Hebrew word for tree, wood, and most importantly log is "עץ", which is pronounced like "etz".

Contributing

Stars are always welcome!

For bugs and feature requests, please create an issue.

License

MIT © Tomer Aberbach
Apache 2.0 © Google

Keywords

logger

FAQs

Package last updated on 01 Sep 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts