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

@nudge-ui/mcp

v0.2.1

Published

Optional local MCP companion for pairing Nudge UI with coding agents.

Readme

@nudge-ui/mcp

Early alpha: This integration can make breaking changes while host support and the setup workflow stabilize.

@nudge-ui/mcp connects a local Nudge inspector to an MCP-capable coding agent. The development server owns the browser bridge. The agent host starts a small stdio adapter that discovers live bridges in the current checkout or Git worktree.

Configure an agent

The Nudge initializer can install the dependency and configure supported agent hosts. A manual project-scoped configuration uses this command:

node ./node_modules/@nudge-ui/mcp/dist/cli.mjs --workspace-root /path/to/project

The adapter does not need an origin, port, project ID, or branch. A running development integration registers those values in a private per-user runtime directory. Restart the agent host after changing its MCP configuration, then ask it to Listen to Nudge. Agent configuration contains absolute checkout and application paths, so rerun agent setup in each clone or Git worktree that you intend the agent to edit.

Run diagnostics without starting MCP stdio framing:

node ./node_modules/@nudge-ui/mcp/dist/cli.mjs doctor --workspace-root /path/to/project

The doctor reports live and exact-workspace session counts. It never prints control credentials.

Project integration

Framework adapters start and stop the project bridge with the development server:

import { startProjectBridge } from "@nudge-ui/mcp/project";

const runtime = await startProjectBridge({
  workspaceRoot: process.cwd(),
  appRoot: process.cwd(),
  projectId: "my-app",
  origin: "http://localhost:5173",
  allowedOrigins: ["http://127.0.0.1:5173"],
});

// Give browser code only these non-secret values.
console.log(runtime.browser.bridgeUrl, runtime.browser.projectId);

await runtime.close();

origin must be the actual canonical development origin after the framework chooses its port. workspaceRoot defaults to the Git worktree root when one is available and otherwise defaults to appRoot. appRoot distinguishes several applications running from one monorepo.

Each live bridge registers a random session ID, canonical workspace and app paths, optional Git common directory and branch metadata, origin, and loopback endpoint. The descriptor is mode 0600 inside a mode 0700 registry. It also contains a private random credential used only between the bridge and adapter.

The adapter lists all live local sessions through nudge_list_sessions, but it can listen only to sessions whose canonical workspace and configured application path match. An adapter configured at the worktree root can select any app in that worktree explicitly. A branch name or shared Git common directory never causes fallback to another worktree. When several apps run in one workspace, pass the chosen sessionId to nudge_listen. The adapter keeps that app selection across a bridge restart and does not replay old requests.

One adapter owns a selected project session until it closes. Other adapters receive a claimed-session error instead of taking browser work. A heartbeat allows the bridge to recover a claim after an adapter process is killed. Call nudge_release when the user stops listening so another adapter can claim the session without restarting the MCP host.

Legacy coupled mode

Passing --origin retains the previous behavior in which the MCP process also owns its browser bridge:

pnpm exec nudge-mcp \
  --project-id my-app \
  --origin http://localhost:5173 \
  --workspace-root /path/to/my-app

This mode remains available for custom integrations during migration. New framework integrations should use the project-owned bridge.

The agent calls nudge_listen, applies the delivered prompt, reports the result through nudge_report_status, and listens again. Canvas tools remain limited to routes from the paired application origin and agent-owned groups.