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

@go-wind/bi-core

v0.2.3

Published

Framework-agnostic BI dashboard kernel: serializable dashboard schema, dataset resolution, chart engine registry (built-in ECharts adapter), light/dark theme tokens, designer state machine.

Readme

@go-wind/bi-core

框架无关的 BI 仪表盘内核:可序列化 dashboard schema、数据集解析、图表引擎注册表(内置 ECharts 适配器)、亮/暗主题 token、设计器状态机。渲染器(bi-vue / bi-react)与设计器(designer-vue)构建在本包之上。

设计文档:docs/bi-designer.md(schema 规范、引擎接口、分期计划都以它为准)。

Schema v1 速览

const schema = {
  schemaVersion: 1,
  name: "销售看板",
  datasets: [
    { id: "ds_month", name: "月度销售", type: "static", rows: [{ month: "1月", sales: 120 }] },
    { id: "ds_api", name: "远程数据", type: "api", api: { params: { range: "30d" } } },
  ],
  charts: [
    {
      id: "c1", datasetId: "ds_month", type: "bar",
      x: 0, y: 0, w: 6, h: 4,                  // 12 列网格坐标
      encoding: { dimension: "month", measure: "sales" },
    },
  ],
};

硬约束:schema 内不允许出现函数(可序列化)。api 型数据集的取数在渲染器经 resolvers[datasetId] 注入;图表点击事件经 bindEvents 归一化回调。

引擎扩展

import { registerEngine } from "@go-wind/bi-core";

registerEngine("g6", createG6Engine()); // 实现.ChartEngine 三方法即可接入

内置 ECharts(Apache-2.0)按需注册;AntV 系(MIT)按需子包规划中;商业引擎(Highcharts/AG Grid)不接入。

设计器状态机

const api = new BiDesignerApi(schema);
api.subscribe(() => render(api.getSnapshot()));   // React: useSyncExternalStore 同形
api.addChart({ type: "pie" }); api.undo(); api.compact();
api.exportSchema(); api.loadSchema(json);