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

@leeoohoo/ui-apps-devkit

v0.1.14

Published

ChatOS UI Apps DevKit (CLI + templates + sandbox) for building installable ChatOS UI Apps plugins.

Readme

ChatOS UI Apps DevKit

一个可通过 npm 安装的 DevKit,用来:

  • 生成 UI Apps 插件工程(脚手架)
  • 在本地沙箱里运行/调试 module 应用(Host API mock)
  • 校验 plugin.json 与路径边界
  • 打包/安装到本机 ChatOS(用户插件目录:<stateDir>/ui_apps/pluginsstateDir = <stateRoot>/<hostApp>

安装

npm i -g @leeoohoo/ui-apps-devkit

或直接用 npx:

npx @leeoohoo/ui-apps-devkit chatos-uiapp --help

快速开始

chatos-uiapp init my-first-uiapp
cd my-first-uiapp
npm install
npm run dev

沙箱能力

  • 模拟 module mount()host.* API
  • 右上角 Theme 切换(light/dark/system),用于测试 host.theme.onChange 与样式响应
  • Inspect 面板展示 host.context--ds-* tokens
  • 右上角 AI Config 可配置 API Key / Base URL / Model ID,用于在沙箱内调用真实模型并测试应用 MCP(需配置 ai.mcp

模板

chatos-uiapp init --list-templates
chatos-uiapp init my-app --template basic
chatos-uiapp init my-app --template notepad
  • basic:最小可运行骨架(含 host.chat.* / ctx.llm.complete() 示例)
  • notepad:完整示例应用(文件夹/标签/搜索/后端持久化)

完成开发后:

npm run validate
npm run pack
npm run install:chatos

MCP 依赖(必读)

  • ChatOS 导入插件时会排除 node_modules/,MCP server 运行时无法读取随包依赖。
  • MCP server 只要引入第三方依赖(如 @modelcontextprotocol/sdkzod),就必须在 build 阶段 bundle 成单文件,并在 plugin.jsonai.mcp.entry 指向 bundle 产物。
  • 如果 MCP 启动报错 Cannot find package '@modelcontextprotocol/sdk',说明依赖未被 bundle 或 vendoring 到插件目录。
  • 或者完全使用 Node 内置模块,或把依赖源码 vendoring 到插件目录内。

生成项目结构(约定)

生成的工程里,可安装产物固定在 plugin/ 目录:

my-first-uiapp/
  docs/                # 协议文档(随工程分发)
  chatos.config.json   # DevKit 配置(pluginDir/appId)
  plugin/              # 直接导入/安装到 ChatOS 的插件目录
    plugin.json
    backend/           # (可选) Electron main 进程后端
    apps/<appId>/      # module 前端 + AI 贡献(MCP/Prompt)

CLI

  • chatos-uiapp init <dir>:生成工程
  • chatos-uiapp dev:启动本地运行沙箱(支持文件变更自动重载)
  • chatos-uiapp validate:校验 manifest 与路径边界
  • chatos-uiapp pack:打包 .zip(用于 ChatOS 导入)
  • chatos-uiapp install:复制到本机 ChatOS 用户插件目录