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

@mg21st/dev-assist

v1.0.4

Published

All-in-one developer toolkit: Auto Test Generator, API Docs Generator, and API Testing UI

Readme

DevAssist 🚀

All-in-one developer toolkit: Auto Test Generator, API Docs Generator & API Testing UI

npm version License: MIT

Features

  • 🧪 Auto Test Generator - AST-based test stub generation or LLM-powered real test generation for JS/TS
  • 🤖 LLM Support - Generate production-quality tests with OpenAI, Gemini, Groq, OpenRouter, Anthropic, or local Ollama
  • 📚 API Docs Generator - Extract Express routes and generate OpenAPI specs + Markdown
  • 🌐 Local UI Server - Beautiful React UI with dashboard, tests viewer, API docs browser
  • API Testing Tab - Lightweight Postman-like HTTP client built-in
  • 🧙 Interactive CLI Wizard - Guided setup experience

Installation

npm install -g @mg21st/dev-assist

Usage

Interactive wizard

dev-assist

Generate tests

dev-assist generate --tests --source ./src --output ./__tests__ --framework jest

Generate API docs

dev-assist generate --docs --source ./src --output ./docs

Generate both

dev-assist generate --source ./src

Start UI server

dev-assist serve --port 3000

Configuration

Create dev-assist.config.js in your project root:

module.exports = {
  testFramework: 'jest',     // 'jest' | 'vitest'
  sourceDir: './src',
  testOutputDir: './__tests__',
  docsOutputDir: './docs',
  port: 3000,
  watchMode: false,
  baseUrl: 'http://localhost:3000',

  // Optional: configure an LLM to generate real, production-quality tests
  // llm: { provider: 'openai', model: 'gpt-4o', apiKey: process.env.OPENAI_API_KEY },
};

LLM-Powered Test Generation

When an llm configuration is provided, DevAssist reads each source file in full and sends it to the LLM with a prompt that requests comprehensive test coverage: happy paths, edge cases, error handling, and boundary conditions. The result is a real test file, not just stubs.

If the LLM call fails for any file, DevAssist automatically falls back to AST-based stub generation for that file.

Supported LLM Providers

| Provider | provider value | Requires API key | |----------|-----------------|-----------------| | Ollama (local) | ollama | No | | OpenAI | openai | Yes | | Google Gemini | gemini | Yes | | Groq | groq | Yes | | OpenRouter | openrouter | Yes | | Anthropic Claude | anthropic | Yes |

LLM Configuration Examples

// Ollama (local, no key required)
llm: { provider: 'ollama', model: 'llama3' }

// OpenAI
llm: { provider: 'openai', model: 'gpt-4o', apiKey: process.env.OPENAI_API_KEY }

// Google Gemini
llm: { provider: 'gemini', model: 'gemini-1.5-flash', apiKey: process.env.GEMINI_API_KEY }

// Groq
llm: { provider: 'groq', model: 'llama-3.3-70b-versatile', apiKey: process.env.GROQ_API_KEY }

// OpenRouter
llm: { provider: 'openrouter', model: 'openai/gpt-4o', apiKey: process.env.OPENROUTER_API_KEY }

// Anthropic
llm: { provider: 'anthropic', model: 'claude-3-5-sonnet-20241022', apiKey: process.env.ANTHROPIC_API_KEY }

You can also set a custom baseUrl for any provider (useful for self-hosted models or proxies):

llm: { provider: 'ollama', model: 'mistral', baseUrl: 'http://my-server:11434' }

Via the Interactive Wizard

When running dev-assist interactively and choosing test generation, the wizard will ask whether you want to use an LLM and guide you through provider and model selection.

Via the UI Server API

When using dev-assist serve, you can pass an llm object in the body of POST /api/generate/tests:

{
  "sourceDir": "./src",
  "outputDir": "./__tests__",
  "framework": "jest",
  "llm": {
    "provider": "openai",
    "model": "gpt-4o",
    "apiKey": "sk-..."
  }
}

Development Setup

Prerequisites

  • Node.js >= 16
  • npm >= 7

Build

# Install root dependencies
npm install

# Install UI dependencies
cd ui && npm install && cd ..

# Build everything
npm run build

Run in development

npm run dev

Architecture

dev-assist/
  bin/                    # CLI entry point
  src/
    cli/                  # Commander + Inquirer CLI
    generators/           # Test & docs generators
    llm/                  # LLM provider abstraction (OpenAI, Gemini, Groq, OpenRouter, Anthropic, Ollama)
    parser/               # @babel/parser AST parser
    server/               # Express backend API
    shared/               # TypeScript types
  ui/                     # React + Vite + Tailwind frontend

API Endpoints (Server)

| Method | Path | Description | |--------|------|-------------| | GET | /api/config | Current configuration (LLM API key is redacted) | | GET | /api/summary | Project statistics | | GET | /api/files | Parsed file list | | GET | /api/tests | Generated test files | | GET | /api/docs | API documentation | | POST | /api/generate/tests | Trigger test generation (accepts optional llm body field) | | POST | /api/generate/docs | Trigger docs generation | | POST | /api/proxy | Proxy HTTP requests (API testing) |

License

MIT