npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

@transloadit/sev-logger

v0.1.5

Published

> Even though this module is publicly accessible, we do not recommend using it in projects outside of [Transloadit](https://transloadit.com). We won't make any guarantees about its workings and can change things at any time, we won't adhere strictly to Se

Readme

Even though this module is publicly accessible, we do not recommend using it in projects outside of Transloadit. We won't make any guarantees about its workings and can change things at any time, we won't adhere strictly to SemVer.

This module is maintained from a monorepo called monolib.

Overview

@transloadit/sev-logger is a lightweight, printf-style logger with:

  • syslog-like levels (EMERG..TRACE) and breadcrumbs
  • breadcrumb nesting that auto-pads prefixes so multi-logger output aligns
  • structured events (logger.event) alongside formatted lines
  • optional timestamps, hostnames, callsites, and clickable paths (each path segment is clickable)
  • built-in redaction of secrets (enabled by default)
  • ESM/CJS friendly, no runtime deps beyond Node
  • Node.js only (browser not supported today)

Install

yarn add @transloadit/sev-logger
# or
npm install @transloadit/sev-logger

Quickstart

import { SevLogger } from '@transloadit/sev-logger'

const log = new SevLogger({ breadcrumbs: ['api'] })
log.info('listening on %s', 'http://localhost:3000')

log.event(SevLogger.LEVEL.NOTICE, {
  event: 'user.login',
  userId: 42,
})

Redaction (on by default)

Secrets are masked before anything is written to stdout/stderr/files. Defaults include:

  • Field names: token, secret, password, pass, authorization, auth, api_key, x-api-key, cookie, session, bearer, …
  • Patterns: Slack tokens, Bearer/JWT-like strings, AWS AKIA/ASIA keys, 40+ char base64ish strings
  • High-entropy fallback for token-like strings
  • Works for formatted logs and event() payloads, even when fields are abbreviated.

Repeated references and cycles are preserved (no stack overflows, shared refs stay shared). Non-plain objects such as Date, URL, RegExp, Map, Set, custom classes, and Error/AggregateError causes are retained.

Basic usage (default redaction on):

const log = new SevLogger({ breadcrumbs: ['botty'] })
log.info('token: %s', process.env.SLACK_BOT_TOKEN) // => token: [redacted]
log.event(SevLogger.LEVEL.INFO, {
  event: 'botty.start',
  headers: { Authorization: `Bearer ${process.env.SLACK_BOT_TOKEN}` },
}) // => headers.Authorization: "[redacted]"

Configuration (override defaults):

const log = new SevLogger({
  redact: {
    enabled: true,          // default true
    replacement: '[redacted]',
    keepLast: 4,            // tail to keep visible, default 4
    fields: ['sessionId'],  // extra field names to always mask (case-insensitive)
    patterns: [/SUPERSECRET\w+/g], // extra regexes
    entropy: true,          // mask random high-entropy strings
    custom: [(
      value, path, // path = ['payload', 'headers', 'authorization'] etc.
    ) => (typeof value === 'string' ? value.replace(/abc/g, '***') : value)],
  },
})

// Opt-out completely
const noRedact = new SevLogger({ redact: false })

Events vs formatted lines

  • logger.info('File %s', '/tmp/foo') — printf-style with %s/%r/%c for strings/paths/clickables.
  • logger.event(level, { event: 'upload.finished', userId, size }) — emits event name + JSON payload (with optional key abbreviations).

Testing

cd packages/sev-logger
yarn test