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

bizchat

v2.0.3

Published

CLI client for workers-chat

Readme

BizChat CLI

A modern terminal-based chat client for workers-chat.

Features

  • 🌐 Join public chat rooms
  • 🔒 Create private, password-protected rooms
  • 💬 Real-time messaging with WebSocket connection
  • 👥 Live user roster
  • 🎨 Beautiful terminal UI with colors and borders
  • ⌨️ Full keyboard navigation
  • 🔄 Automatic reconnection on connection loss
  • 📱 Responsive design that adapts to terminal size

Installation

# Install dependencies
npm install

# Make the CLI executable
chmod +x index.js

Usage

Interactive Mode (Recommended)

Simply run the CLI and follow the prompts:

npm start

Command Line Options

You can also provide options directly:

# Basic usage
node index.js

# Specify username and room
node index.js --username "John" --room "general"

# Join a password-protected room
node index.js --username "John" --room "private-room" --password "secret"

# Use a different server
node index.js --host "myserver.com:8080"

Available Options

  • -u, --username <username> - Your username
  • -r, --room <room> - Room to join
  • -p, --password <password> - Room password (if required)
  • -h, --host <host> - Chat server hostname (default: localhost:8787)
  • --help - Show help
  • --version - Show version

Controls

Navigation

  • Arrow Keys (↑↓) - Navigate menu options (during setup)
  • Enter - Select option or send message
  • Tab - Switch between input areas (where applicable)

Chat Interface

  • Type and Enter - Send a message
  • ESC - Go back or quit
  • Ctrl+C - Quit application

Room Types

Public Rooms

  • Open to everyone who knows the room name
  • No password required
  • Messages are visible to all participants

Private Rooms

  • Created with a custom name
  • Optionally password-protected
  • More secure and controlled access

Architecture

The CLI is built with a modular architecture:

bizchat/
├── index.js                # Main entry point
├── src/
│   ├── ChatApp.js          # Main application orchestrator
│   ├── UserInterface.js    # Terminal UI handling
│   ├── WebSocketClient.js  # WebSocket connection management
│   └── RoomManager.js      # Room creation and management
├── package.json
└── README.md

Key Components

  • ChatApp: Main application coordinator that manages the flow
  • UserInterface: Handles all terminal rendering and user input
  • WebSocketClient: Manages WebSocket connections with auto-reconnect
  • RoomManager: Handles room creation and password checking

Dependencies

  • commander: Command-line argument parsing
  • inquirer: Interactive command-line prompts
  • chalk: Terminal string styling
  • ora: Loading spinners
  • boxen: Terminal boxes
  • terminal-kit: Advanced terminal control
  • ws: WebSocket client
  • node-fetch: HTTP requests
  • gradient-string: Gradient text effects
  • figlet: ASCII art text

Troubleshooting

Connection Issues

  • Ensure the workers-chat server is running on the specified host
  • Check your network connection
  • Try connecting to a different room

Input Problems

  • Make sure your terminal supports the required features
  • Try resizing your terminal window
  • Restart the application if input becomes unresponsive

Password Issues

  • Ensure you're entering the correct password
  • Check if the room actually requires a password
  • Try creating a new room with a different name

Development

Project Structure

  • index.js - Entry point with CLI argument parsing
  • src/ChatApp.js - Main application logic
  • src/UserInterface.js - Terminal UI using terminal-kit
  • src/WebSocketClient.js - WebSocket handling with EventEmitter
  • src/RoomManager.js - HTTP API interactions

Running in Development

npm run dev

Features Implemented

  • ✅ Interactive setup wizard
  • ✅ Command-line argument support
  • ✅ Real-time chat with WebSocket
  • ✅ User roster management
  • ✅ Password-protected rooms
  • ✅ Auto-reconnection
  • ✅ Responsive terminal UI
  • ✅ Proper error handling
  • ✅ Keyboard navigation

License

MIT License