@blueprint-chart/editor

中文文档
2.15.0发布于 2026/11/08MITES Module构建来源已验证近 30 天下载 2476

Blueprint Chart editor — static site bundle. Self-host or use the live version at https://blueprintchart.com.

原始使用文档
文档目录8 节
  1. Live version
  2. Self-host
  3. Develop
  4. Optional: Accounts & hosted charts (Supabase)
  5. 1. Create a Supabase project and apply the schema
  6. 2. Configure credentials
  7. 3. Auth provider
  8. License

@blueprint-chart/editor

Static-site bundle of the Blueprint Chart editor. Use it self-hosted or via the live version at blueprintchart.com.

Live version

https://blueprintchart.com

Self-host

Install the package and point any static file server at the dist/ directory.

npm install @blueprint-chart/editor
npx serve node_modules/@blueprint-chart/editor/dist

Or copy node_modules/@blueprint-chart/editor/dist/* into your own static hosting (S3, Nginx, GitHub Pages, etc.).

Develop

See the main repository for development instructions.

Optional: Accounts & hosted charts (Supabase)

The editor works fully without an account — charts live in your browser and embed via self-contained base64 links. To additionally let users sign in, store charts in the cloud, and publish live permalinks, configure Supabase.

1. Create a Supabase project and apply the schema

The schema lives in packages/editor/supabase/migrations/20260601000000_charts.sql (creates the charts table and RLS policies — owner full access; public read of published charts). Apply it with either method:

A. Supabase SQL Editor (no tooling). Open your project → SQL Editor → paste the file contents → Run. Always works.

B. Supabase CLI. This repo ships a ready packages/editor/supabase/ project, so from that directory:

cd packages/editor
supabase link --project-ref YOUR-PROJECT-REF
supabase db push

db push only recognizes migrations named <timestamp>_name.sql and reads them from the supabase/ project it's run against — hence cd packages/editor first. If you keep your own supabase/ project elsewhere, copy 20260601000000_charts.sql into its supabase/migrations/ (keep the timestamped name) before running supabase db push.

2. Configure credentials

Either bake them at build time:

VITE_SUPABASE_URL=https://YOUR-PROJECT.supabase.co
VITE_SUPABASE_ANON_KEY=YOUR-PUBLIC-ANON-KEY

…or deploy a runtime config.json next to index.html (overrides env, so one build can be configured per deploy — see config.example.json):

{ "supabaseUrl": "https://YOUR-PROJECT.supabase.co", "supabaseAnonKey": "YOUR-PUBLIC-ANON-KEY" }

If neither is set (or only one value is present), the accounts feature stays off and the editor behaves exactly as the self-contained build.

3. Auth provider

Sign-in uses passwordless magic links. In your Supabase project enable the Email provider and add your deployed origin to the allowed redirect URLs.

License

MIT

版本与发布记录

@blueprint-chart/editor 共发布 65 个版本,首次发布于 2026/05/15;过去 12 个月发布了 65 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
2.15.0latest2026/11/08今天
2.14.02026/11/08今天
2.13.02026/11/08今天
2.12.02026/11/08今天
2.11.02026/11/08今天
2.10.02026/11/071 天前

关于 @blueprint-chart/editor 的常见问题

@blueprint-chart/editor 是什么?

Blueprint Chart editor — static site bundle. Self-host or use the live version at https://blueprintchart.com.

如何安装 @blueprint-chart/editor?

在项目目录运行 npm install @blueprint-chart/editor,或使用 pnpm add / yarn add / bun add。

@blueprint-chart/editor 支持 TypeScript 吗?

该包的 package.json 没有声明类型入口。需要类型提示时,可以在 npm 上查找社区维护的 @types/blueprint-chart__editor 是否存在。

@blueprint-chart/editor 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@blueprint-chart/editor 可以商用吗?

@blueprint-chart/editor 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@blueprint-chart/editor 的下载量有多少?

根据 npm 官方下载统计,@blueprint-chart/editor 在 2026/10/09 – 2026/11/07 这 30 天内被下载 2,476 次,日均约 83 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@blueprint-chart/editor 还在维护吗?

最新版本 2.15.0 发布于 2026/11/08(今天);至今共发布 65 个版本,其中过去 12 个月发布了 65 个;首次发布于 2026/05/15。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。