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

mini-blessed

v1.1.2

Published

Mini Blessed

Readme

Mini Blessed - Terminal control

Uses the Blessed API for a simplified experience with Blessed in TypeScript (maybe js - untested)

Install

npm install mini-blessed@latest

First run

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

Mini.Console.log("Hi from mini-blessed!");

Simple console output

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

Mini.Console.log("this is log");
Mini.Console.warn("this is warn (yellow)");
Mini.Console.error("this is error (red)");
Mini.Console.critical("this is critical error (pulse red text <-> red background && black text");

Colored output

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

// Red text
Mini.Console.log(`${COLORS.FG.RED}Red text!${COLORS.RESET}`) // "COLORS.RESET" VERY IMPORTANT!!!
// Bright green color
Mini.Console.log(`${COLORS.FG.BRIGHT.GREEN}Light green text!${COLORS.RESET}`);
// Cyan background + black text
Mini.Console.log(`${COLORS.BG.CYAN}${COLORS.FG.BLACK}Multi-coloring!${COLORS.RESET}`);
// Bold text
Mini.Console.log(`${COLORS.STYLE.BOLD}Bold text!${COLORS.RESET}`);
// Underlined text
Mini.Console.log(`${COLORS.STYLE.UNDERLINED}Underlined text${COLORS.RESET}`);

Advanced output

Advanced output also supports color output

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

// Send custom output
Mini.Custom.addLog("UNIQUE_ID", "TEXT", {});

// Clear one log
Mini.Custom.removeLog("UNIQUE_LOG_ID");

// Clean all screen
Mini.Custom.cleanScreen();

⚠️ WARNING Unique log names (Mini.Custom.addLog("UNIQUE_NAME!!!", ...) must be unique for the ENTIRE PROJECT!

Advanced dynamic output

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

// Calling first green message
const onlog = Mini.Custom.Log("mylog", `${COLORS.FG.GREEN}First log${COLORS.RESET}`, {
    updateInterval: 100, // Minimum text refresh rate (ms)
    width: 50 // max output width before and after changing (symbols)
});

// Replace the text of the first line with a new one in 2 seconds 
setTimeout(() => {
    onlog?.update(`${COLORS.FG.RED}New red log!${COLORS.RESET}`);
}, 2000)

Key reader

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

// Kill the app when pressed ESC / Q / Ctrl+C keys
Mini.screen.key(['escape', 'q', 'C-c'], () => process.exit(0));

Basic input

⚠️ Only in main file!!! Don't works in export modules

import { MiniBlessed as Mini, COLORS } from 'mini-blessed';

const main: () => Promise<void> = async () => {
    const $name: any = await Mini.Input.text("Your name: ");
    const $age: any = await Mini.Input.text("Age: ");
    Mini.Console.log(`Name: ${$name}\nAge: ${$age}`);
}
main();

Result: Your Name: Vasiliy Age: 25 Name: Vasiliy Age: 25

Color input

>= 1.1.1

import { MiniBlessed as Mini, COLORS } from './index';

const name: any = await Mini.Input.text(`Enter your name: `, {    
    prefixFg: COLORS.FG.RED, // Don't supports BRIGHT colors
    prefixBg: COLORS.BG.WHITE, // Don't supports BRIGHT colors
    inputFg: COLORS.FG.BLUE,// Don't supports BRIGHT colors
    inputBg: COLORS.BG.GREEN // Don't supports BRIGHT colors,
    width: 50
});
Mini.Console.log(name);
/*
    'Enter your name: ' - red foreground and white background
    User input - blue foreground and green background
*/

Advanced color input

>= 1.1.1

import { MiniBlessed as Mini, COLORS } from './index';

const Name: any = await Mini.Input.text([
        { text: "Enter ", fg: COLORS.FG.WHITE },
        { text: "your name", fg: COLORS.FG.RED, bg: COLORS.BG.YELLOW + COLORS.STYLE.BOLD },
        { text: ": ", fg: COLORS.FG.WHITE }
    ], {
        inputFg: COLORS.FG.GREEN,
        inputBg: COLORS.BG.BRIGHT.BLACK
});
Mini.Console.success(`Hi, ${Name}!`); 
/*
    'Enter ' - white foreground
    'your name' - bold, red foreground, yellow background
    ': ' - white foreground
*/

Input key validation

>= 1.1.1

import { MiniBlessed as Mini, COLORS } from './index';

const Name: any = await Mini.Input.text([
        { text: "Enter ", fg: COLORS.FG.WHITE },
        { text: "your name", fg: COLORS.FG.RED, bg: COLORS.BG.YELLOW + COLORS.STYLE.BOLD },
        { text: ": ", fg: COLORS.FG.WHITE }
    ], {
        inputFg: COLORS.FG.GREEN,
        inputBg: COLORS.BG.BRIGHT.BLACK,
        customKeys: {
            'escape': (input) => { input.setValue("Skip"); input.submit(); } // pressed 'ESC' => putted 'Skip' and submitted (important input.submit()!)
        } 
});

if (Name !== 'Skip') {
    Mini.Console.success(`Hi, ${Name}!`); 
} else {
    Mini.Console.error("Name skipped");
}

TODO

  • [x] ~~Basic console operations~~
  • [x] ~~Advanced console operations~~
  • [x] ~~Basic input~~
  • [x] ~~Advanced input (color customizer)~~
  • [ ] Advanced input (input validation)
  • [ ] Advanced input (radio menu)
  • [ ] Advanced input (select menu)
  • [ ] Basic progressbars
  • [ ] Advanced progressbars

Dependencies

  • blessed
  • node-fetch
  • @types/node