refactor(demo): 修复 ECharts 表格图表功能并优化代码#1693
Conversation
- 修复 enableChart 被错误设置为对象而非布尔值的 bug - 简化配置逻辑,使用三元运算符替代 if-else - 统一插件加载逻辑,减少重复代码 - 添加详细的 JSDoc 注释和使用文档 - 添加快速开始指南和最佳实践建议 关键修复: - enableChart 必须是布尔值 true,不能是 ECharts 对象 - Table hook 使用严格相等检查 enableChart === true
🦋 Changeset detectedLatest commit: 90b0bea The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
commit: |
【预览链接】
|
|
Size Change: -77 B (0%) Total Size: 7.84 MB 📦 View Changed
ℹ️ View Unchanged
|
|
📦 cherry-markdown dev preview published
Install NPM with : pnpm add cherry-markdown@npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7yarn add cherry-markdown@npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7npm i cherry-markdown@npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7如果你使用了其他以 cherry-markdown 作为同等依赖(peer dependency)的元框架,你需要在 package.json 文件中覆盖 cherry-markdown 依赖,具体操作方式会因你使用的包管理器而略有不同 If you use a meta framework that has cherry-markdown as peer dependency, you have to override the cherry-markdown dependency in your package.json, which works slightly different depending on your package manager # npm
{
"overrides": {
"cherry-markdown": "npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7"
}
}
# yarn
{
"resolutions": {
"cherry-markdown": "npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7"
}
}
# pnpm
{
"pnpm": {
"overrides": {
"cherry-markdown": "npm:@cherry-markdown/cherry-markdown-dev@0.11.0-alpha-5-202604140223.1bbdab7"
}
}
}在添加 overrides 之后,重新安装你的依赖并像往常一样启动你的开发服务器或构建你的项目即可,无需进一步的配置更改 After adding these overrides, reinstall your dependencies and start your development server or build your project as usual. No further configuration changes are required |
* fix(demo): 修复 ECharts 表格图表功能并优化代码 - 修复 enableChart 被错误设置为对象而非布尔值的 bug - 简化配置逻辑,使用三元运算符替代 if-else - 统一插件加载逻辑,减少重复代码 - 添加详细的 JSDoc 注释和使用文档 - 添加快速开始指南和最佳实践建议 关键修复: - enableChart 必须是布尔值 true,不能是 ECharts 对象 - Table hook 使用严格相等检查 enableChart === true * docs: 更新流式渲染示例代码与滚动逻辑 * fix: 修复 addons 构建缺少环境变量替换导致运行时报错的问题 * fix(examples): 优化流式打印和插件加载体验 * refactor(examples): 移除流式聊天自动滚动逻辑
关键修复: