mdxcn README

项目的 README,来自 github.com/shadcn-labs/mdxcn。合并为一个 markdown 文件:README.md。

mdxcn banner

mdxcn

Free & open-source, ready-to-use, customizable Markdown-friendly components for React.
Copy the source into your app. Built for MDX, works seamlessly with shadcn/ui.

GitHub Stars CI Discord Members X Follow

Get Started · Installation · Components

Features

Community

The mdxcn community lives on GitHub, where you can ask questions, share ideas, and show what you've built.

Contributing

Contributions are welcome. See CONTRIBUTING.md to get the repo running locally and land a change, and use issues and discussions to collaborate. By participating, you agree to the Code of Conduct.

Security

Please do not open public issues for security vulnerabilities. Follow SECURITY.md and report them privately through GitHub Security Advisories.

License

MIT

Contributors

Contributors

Made with contrib.rocks

Star History

Star History Chart

mdxcn (shadcn-labs/mdxcn)

正在搜索数据库…

这是什么?mdxcn 是一套免费开源的 ASCII 风格 React 组件——表格、图表、时间线、流程图等等——用来与正文并排出现在 MDX 或纯 Markdown 中,设计上是被复制进你自己的项目,而不是作为包安装。
这是我要安装的 npm 包,还是把代码复制进去?它不是 npm 包。你使用 shadcn CLI 把单个组件(graph-table、graph-flow、graph-timeline 这类 registry 项)添加到自己的代码库里,CLI 会把源文件直接复制进你的项目。
我怎么把这些图表组件添加到我的项目里?运行 shadcn CLI 指向 mdxcn 的 scoped registry(或粘贴完整的 registry URL)来添加组件——它会把文件放到 @/registry/default 下;改动之后你要运行 `shadcn build` 重新构建 registry。
安装组件之前我需要准备什么?你需要一个已经配置好的 shadcn 项目,并安装 motion 包,因为这些组件使用 Motion 来实现变换/透明度过渡。
我能在 MDX/React 之外使用这些图表吗?可以——Comark 应用可以从普通 .md 文件里的纯 `::graph-` 代码块渲染同样的图形,完全不需要 MDX;围栏 ASCII 形式甚至可以直接放进纯 GitHub README。
包含多少种图表类型?开箱即用的组件超过 30 个——比如 Table、Flow、Bars、Timeline、Gantt、Heatmap、Waterfall、Rank、KPI 和 Countdown——README 里逐一列出了它们的 registry 名称和典型用途。
为什么用 ASCII 而不是 SVG 图表?每个图表都刻意用等宽字符绘制在虚线的 Geist Mono 边框内,而不是 SVG,让图形保持轻量,并与周围的代码或正文在视觉上保持一致。
Comark 是什么?Comark 是 mdxcn 同样支持的一类 Markdown 工具,它从普通 .md 文件里的 `::graph-` 围栏代码块渲染同样的图形,让非 MDX 的 Markdown 应用也能显示它们。
编程智能体怎么使用它?mdxcn 提供一个技能和一个 /llms.txt 端点,告诉智能体应该在正文旁边放置哪种图表,涵盖 MDX 用的 JSX、Comark 用的 ::graph- 语法,以及纯 GitHub README 用的围栏 ASCII。
大小
1.9 MB
星标
713
更新
提交Nov 11
时长
3个月
提交 · 90 天