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 🙏

© 2026 – Pkg Stats / Ryan Hefner

ultralog

v0.2.5

Published

Simple opinionated logging module for NodeJs

Readme

ultralog

Simple opinionated logging module for NodeJs.

Overview

Ultralog is a simple and lightweight logging framework for any Node.js application. It provides a common wrapper for logging to various targets, including the console, files, AWS CloudWatch, GCP Stackdriver, and OpenSearch. The library is designed to be modular, allowing you to install only the dependencies you need.

Installation

npm install ultralog

Usage

Here's a simple example of how to use the Logger class:

import { Logger } from "ultralog";

// Create a new logger instance
const logger = new Logger("console");

// Log a message
logger.info("Hello, world!");

Transports

Ultralog supports the following transports:

  • console: Logs to the console.
  • file: Logs to a file.
  • aws: Logs to AWS CloudWatch.
  • gcp: Logs to GCP Stackdriver.
  • opensearch: Logs to OpenSearch.

You can specify the transport in the Logger constructor:

// Use the file transport
const fileLogger = new Logger("file", { filename: "app.log" });

// Use the AWS CloudWatch transport
const awsLogger = new Logger("aws", {
  logGroupName: "my-log-group",
  logStreamName: "my-log-stream",
  region: "us-east-1",
  accessKeyId: "YOUR_AWS_ACCESS_KEY_ID",
  secretAccessKey: "YOUR_AWS_SECRET_ACCESS_KEY",
});

// Use the OpenSearch transport
const opensearchLogger = new Logger("opensearch", {
  node: "http://localhost:9200",
  index: "logs",
  // Additional OpenSearch configuration options
});

Optional Dependencies

To use the aws, gcp, or opensearch transports, you'll need to install some optional dependencies.

AWS CloudWatch

To log to AWS CloudWatch, you'll need to install the winston-cloudwatch package:

npm install winston-cloudwatch

GCP Stackdriver

To log to GCP Stackdriver, you'll need to install the @google-cloud/logging-winston package:

npm install @google-cloud/logging-winston

OpenSearch

To log to OpenSearch, you'll need to install the winston-opensearch package:

npm install winston-opensearch

Verbosity

You can enable verbose logging to include additional information in your log messages, such as the timestamp and log level.

const logger = new Logger("console");

// Enable verbose logging
logger.setVerbose(true);

// This will log a more detailed message
logger.info("This is a verbose log message.");

Contribution and Issues

Visit https://github.com/ashubisht/ultralog for more details. Raise issues at https://github.com/ashubisht/ultralog/issues.