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

@flow3d/devtools

v0.1.0

Published

Flow3D developer tools — CLI document validator, graph inspector panel and perf HUD.

Downloads

689

Readme

@flow3d/devtools

Flow3D 开发者工具(M6 交付):文档校验 CLI、浏览器图检查器面板与性能 HUD。 本包不引入 three,仅依赖 @flow3d/core 的公共 API 与 DOM,可在 Node 与浏览器两端使用。

安装

pnpm add @flow3d/devtools

CLI(Node 端)

# 静态校验一份图文档;error>0 退出码 1,--strict 时 warning>0 也退出码 1
flow3d-devtools validate path/to/doc.json [--strict]

# 输出结构化的检查摘要(节点/流计数、单位、布局策略、归一化位置)
flow3d-devtools inspect path/to/doc.json

validate 复用 core 的 validateStatic;inspect 在通过静态校验后额外调用 normalizeGraph 补全每个节点的解析后位置与状态。文件读取失败退出码 2。

浏览器端(面板 / HUD)

import { createInspector, createHud } from '@flow3d/devtools';
import type { SceneHandle } from '@flow3d/devtools';

// 检查器面板:列出节点/流,点击节点即聚焦(FR-22)
const inspector = createInspector({ container: canvas.parentElement!, scene });
// 性能 HUD:悬浮显示 FPS / 节点数 / 流数 / 最近一次 apply 耗时
const hud = createHud({ container: canvas.parentElement!, scene });

// 不再需要时清理(移除 DOM 与事件订阅)
inspector.dispose();
hud.dispose();

scene 的类型是导出的结构接口 SceneHandle——它只描述 listNodes() / listFlows() / focus() / events 子集,刻意不引用 core 的 FlowScene 类本身,便于解耦与 tree-shaking。 真实的 FlowScene 因结构兼容可直接传入。

公共 API

  • 纯函数:validateDocument(doc)、inspectDocument(doc)、defaultValidationContext()
  • 面板:createInspector(options) / createHud(options)(返回带 dispose() 的句柄)
  • 类型:InspectSummary / InspectNodeSummary / InspectFlowSummary / InspectorOptions / InspectorHandle / HudOptions / HudHandle / SceneHandle
  • 常量:VERSION

设计依据

见仓库 docs/01-Flow3D-技术设计文档.md 与 docs/03-Flow3D-实现确定性附录.md。 任何实现细节以这两份文档为准。

License

MIT