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

litemap

v1.38.0

Published

A TypeScript library for mapping and processing data with SQLite integration

Downloads

16

Readme

Litemap

A lightweight, persistent key-value database for Node.js, designed for simple user and item storage with SQLite as the backend. Litemap provides an easy-to-use API for managing users, items, and other records, making it ideal for bots, and other various apps.

npm npm version license GitHub stars


Features

  • 💾 Persistent storage – Data is saved to disk using SQLite.
    • Any updates to the database will be stored in a queue to prevent "transcation within a transaction"
  • 🔑 Key-value access – Store and retrieve users/items by key.
  • 🏎️ Fast and lightweight – Minimal dependencies, quick operations.
    1. SQLite
    2. SQLite3
  • 🤖 Perfect for bots – Designed for Discord bots and automation scripts.

Installation

npm install litemap

Usage

const { DatabaseFactory } = require("litemap");
const fs = require("fs/promises");

(async () => {
  await fs.mkdir("./db", { recursive: true });
  const dbManager = DatabaseFactory.Instance("./db/litemap.db");

  if (!(await dbManager.getUser("user1"))) {
    await dbManager.addUsers([
      {
        key: "user1",
        value: {
          name: "Mad Hatter",
          role: "superadmin",
          email: "[email protected]",
          createdAt: new Date().toISOString(),
          lastLogin: null,
        },
      },
    ]);
  } else {
    console.log("user1 already exists, skipping creation.");
    if (
      (await dbManager.getUser("user1").lastLogin) !== new Date().toISOString()
    ) {
      await dbManager.updateUser("user1", {
        lastLogin: new Date().toISOString(),
      });
      console.log("Updated last login for user1.");
    }
    dbManager.getUser("user1").then((user) => {
      console.log("Current user1 data:", user);
    });
  }
})();

Exports

const { DatabaseFactory, SQLiteDatabase, UserDatabaseManager } = require("litemap");

Types

You can import types for TypeScript:

import type { IUserRecord, UserRecord } from "litemap";

Example Use Cases

  • Discord bots: Store user profiles, stats, and settings.
  • CLI tools: Save configuration or user data.
  • Web apps: Lightweight persistent storage without a full database server.
  • Prototyping: Quickly persist data during development.