GeezerVison is showing github.com — feat: support SVG renderer in ECharts charts by legions-developer · Pull Request #38 · legions-developer/evilcharts
Conversation
Summary
- add a shared Canvas/SVG renderer API to all eight ECharts chart roots, with Canvas remaining the default
- safely recreate chart instances when the renderer changes and reset renderer-owned interaction state
- add SVG renderer examples, documentation previews, and generated registry artifacts for every ECharts chart type
- highlight the
renderer="svg" line in every example code preview
- document renderer-specific texture behavior for area, bar, and composed charts
- correct the radar chart composability copy identified during review
Validation
bun run lint (0 errors; 7 unrelated baseline warnings)
bunx tsc --noEmit --incremental false
bun run registry:fresh (279 registry items)
bun run build (89 static pages)
- browser QA across all eight SVG previews: one SVG surface, zero canvases, and no runtime errors
- generated install payload audit: all eight SVG examples include the code-highlight marker
- verified all eight ECharts roots and their
main counterparts pass the active react-hooks/refs rule with the pinned ESLint toolchain
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
vercel
Bot
commented
Aug 13, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
coderabbitai
Bot
commented
Aug 13, 2026
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
|

No actionable comments were generated in the recent review. 🎉
ℹ️ Recent review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 61306d87-ffad-4aa0-aebc-ebfe0b623b35
📥 Commits
Reviewing files that changed from the base of the PR and between d31f3c6 and de6e225.
📒 Files selected for processing (1)
src/content/docs/echarts/radar-chart/static.mdx
🚧 Files skipped from review as they are similar to previous changes (1)
- src/content/docs/echarts/radar-chart/static.mdx
📝 Walkthrough
Walkthrough
ECharts now supports Canvas and SVG renderers through shared configuration. Eight chart components accept a renderer prop, SVG examples are registered, and documentation describes renderer selection and behavior.
Changes
ECharts SVG renderer support
| Layer / File(s) |
Summary |
Shared renderer foundation src/registry/ui/echarts-chart.tsx |
Registers Canvas and SVG renderers and exports renderer identifiers, the renderer type, and the Canvas default. |
Chart renderer integration src/registry/charts/echarts-*.tsx |
Adds the renderer prop to eight chart components. Renderer changes recreate chart instances and refresh related effects and state. |
SVG chart examples src/registry/examples/echarts/ex-svg-renderer-* |
Adds SVG examples for area, line, bar, composed, radar, pie, radial, and Sankey charts. |
Example registry wiring registry.json, src/registry/__index__.tsx, src/registry/registry-example.ts |
Registers and lazy-loads the eight SVG examples. |
Renderer documentation src/content/docs/echarts/*, src/content/docs/index.mdx, src/globals/constants/providers.ts, AGENTS.md |
Documents Canvas as the default, SVG through renderer="svg", and renderer-specific chart behavior. |
Estimated code review effort: 3 (Moderate) | ~25 minutes
Merge Risk: 🟡 Moderate · up to de6e2
This change adds SVG rendering while keeping Canvas as the default, but the current head still has ESLint errors in changed loading-effect dependency arrays across the chart roots, so the declared lint check does not pass. Merge should wait for these localized fixes.
Possibly related PRs
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
| Check name |
Status |
Explanation |
Resolution |
| Docstring Coverage |
⚠️ Warning |
Docstring coverage is 46.67% which is insufficient. The required threshold is 80.00%. |
Write docstrings for the functions missing them to satisfy the coverage threshold. |
✅ Passed checks (4 passed)
| Check name |
Status |
Explanation |
| Linked Issues check |
✅ Passed |
Check skipped because no linked issues were found for this pull request. |
| Out of Scope Changes check |
✅ Passed |
Check skipped because no linked issues were found for this pull request. |
| Title check |
✅ Passed |
The title clearly and concisely identifies the main change: adding SVG renderer support to ECharts charts. |
| Description check |
✅ Passed |
The description directly covers the renderer API, chart behavior, examples, documentation, and validation for the changeset. |
✨ Finishing Touches
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Commit unit tests in branch
codex/echarts-svg-renderer
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
❤️ Share
Comment @coderabbitai help to get the list of available commands.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 2770f1ac-184c-43a3-bc8c-4ebec9e6e657
📥 Commits
Reviewing files that changed from the base of the PR and between 53d2b32 and c52ed09.
📒 Files selected for processing (34)
AGENTS.md
registry.json
src/content/docs/echarts/area-chart/static.mdx
src/content/docs/echarts/bar-chart/static.mdx
src/content/docs/echarts/composed-chart/static.mdx
src/content/docs/echarts/installation.mdx
src/content/docs/echarts/line-chart/static.mdx
src/content/docs/echarts/pie-chart/static.mdx
src/content/docs/echarts/radar-chart/static.mdx
src/content/docs/echarts/radial-chart/static.mdx
src/content/docs/echarts/sankey-chart/static.mdx
src/content/docs/echarts/ui/brush.mdx
src/content/docs/index.mdx
src/globals/constants/providers.ts
src/registry/__index__.tsx
src/registry/charts/echarts-area-chart.tsx
src/registry/charts/echarts-bar-chart.tsx
src/registry/charts/echarts-composed-chart.tsx
src/registry/charts/echarts-line-chart.tsx
src/registry/charts/echarts-pie-chart.tsx
src/registry/charts/echarts-radar-chart.tsx
src/registry/charts/echarts-radial-chart.tsx
src/registry/charts/echarts-sankey-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-area-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-bar-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-composed-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-line-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-pie-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-radar-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-radial-chart.tsx
src/registry/examples/echarts/ex-svg-renderer-echarts-sankey-chart.tsx
src/registry/registry-example.ts
src/registry/registry-ui.ts
src/registry/ui/echarts-chart.tsx
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This branch was successfully deployed
1 active
deployment
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|