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

@primeuix/mcp

v2.0.0

Published

Model Context Protocol (MCP) server for PrimeUI Libraries

Readme

PrimeUIX MCP

Shared Model Context Protocol (MCP) v2 server core for PrimeUI libraries. Framework-specific packages load normalized generated docs (mcp-data.json and manifest.json) and use this package to register a compact resource-first MCP surface.

Requires Node.js 22 or newer.

import { createPrimeMcpServer } from '@primeuix/mcp';

const server = await createPrimeMcpServer({
    name: '@primevue/mcp',
    version: '5.0.0-alpha.1',
    loadMcpData: async () => mcpData,
    loadManifest: async () => manifest,
    readResource: async (resource) => readGeneratedFile(resource.path)
});

Default tools are limited to:

  • list
  • search
  • get_component
  • get_guide
  • get_example
  • get_setup
  • validate_usage
  • version

Generated docs are exposed through MCP resources and resource templates for component docs, component API JSON, guide docs, examples, llms.txt, llms-full.txt, and index.json. Workflow prompts are registered with the current SDK registerPrompt API.

Normalized components, guides, sections, and resources may declare an optional absolute HTTP(S) publicUrl. Setup guides may additionally declare a canonical environment and environmentAliases. Tool results keep resourceUri as the offline citation and add publicUrl only when supplied by normalized artifact metadata.

Component search results include an artifact-backed exampleSections inventory. Each entry reports the exact section ID, hasCode, its source resource, and a nextCall containing arguments accepted by get_example. Component results expose the same routing inventory, while nextCall arguments retain the component's mode when the generated artifact requires mode-specific routing.

get_component and validate_usage preserve their single-item inputs and outputs. They also accept bounded batches:

{ "components": [{ "component": "Button" }, { "component": "Table", "sections": ["paginator"] }] }
{
    "usages": [
        { "component": "Button", "code": "<Button />" },
        { "component": "Button", "mode": "tailwind", "code": "<Button variant=\"default\" />" }
    ]
}

Each list accepts 1–10 items. Batch results preserve input order and report per-item success or structured error status; malformed or unknown items do not fail unrelated items. Duplicate items are processed independently. Empty and over-limit lists fail before item work begins.

Usage validation treats metadata completeness as an explicit state. A property value is checked only when its exact generated type is a closed union made entirely of string literals (plus optional null or undefined); extensible strings, named types, bindings, expressions, spreads, wrappers, and conflicting mode evidence are not promoted to hard errors. PrimeNG onX output names are checked only when the exact generated component API contains a well-formed data.emits collection; other unknown listener names may be DOM events and remain non-fatal. Current Vue listener fallthrough and React inherited event props do not prove closed event contracts, so unknown listener names also remain non-fatal there. Diagnostics use deterministic invalid-enum-value and unknown-output codes with artifact resource evidence and never repeat the rejected literal value.

PrimeReact Tailwind currently reuses an API source whose enum values conflict with accepted Tailwind examples. Its enum metadata is therefore classified as incomplete rather than inferred complete from a non-empty property list. Styled and Tailwind modes remain isolated, and requests without a mode do not receive enum or event errors when more than one generated mode matches.

The old broad tool modules are deprecated reference code only. The v2 server factory does not register them and does not provide a legacy runtime fallback.

Search benchmark

The shared core builds one immutable search index lazily for each server instance. The committed benchmark uses the accepted local PrimeVue, PrimeNG, and PrimeReact package artifacts, three warmups, eleven repeated samples, and per-operation medians:

corepack pnpm --filter @primeuix/mcp build
corepack pnpm --filter @primeuix/mcp benchmark

benchmarks/baseline.json records the pre-change environment, accepted artifact commits, and medians. A comparison is valid only when the explicit Node, platform, architecture, OS release, and CPU metadata match. Search must be at most 75% of baseline; component retrieval and validation may regress by at most 10%. The harness uses real monotonic durations and batched fast operations, with no sleeps or mocked timers.

After building the core, run corepack pnpm --filter @primeuix/mcp test:real-artifacts to exercise routing, batching, validation, and the unchanged eight-tool inventory against the accepted local PrimeVue, PrimeNG, and PrimeReact artifacts. PrimeReact coverage is mode-specific for styled, Tailwind, primitive, and headless components.

License

Licensed under the PrimeUI License - Copyright (c) PrimeTek Informatics