본문으로 건너뛰기
cccskills
무료GitHub에 공개

echarts-pro

Build rich visualizations with Apache ECharts: option config, dataset transforms, large-data performance, and custom rendering. Use for complex dashboards and big datasets.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

설치 방법 보기

포함된 파일(1)

  • SKILL.md5.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

ECharts Pro

A practical guide to Apache ECharts: the declarative, canvas/SVG-rendered charting library that scales from simple bars to million-point visualizations — option configuration, datasets, visual mapping, large-data strategies, and custom series.

Overview

ECharts is declarative: you describe the chart as a JSON-ish option object ({ xAxis, yAxis, series }) and call chart.setOption(option). This makes charts serializable, diffable, and easy to generate from data pipelines. Its strengths: enormous chart-type coverage (including geo, graph, sankey, candlestick, heatmap), built-in data transforms, and serious large-dataset performance (incremental rendering, sampling).

When to use

  • Complex dashboards: mixed chart types, rich interactions (brush, dataZoom, toolbox).
  • Large datasets (100k+ points) needing sampling/incremental render.
  • Geo visualizations, network graphs, sankeys, Gantt-like timelines.
  • When charts are generated from data (option objects serialize cleanly).
  • Needing SVG output (accessibility/print) vs canvas (performance).

Core concepts

  • Option. The single config object. setOption(option) renders; setOption(option, { notMerge: true }) replaces; default merges — understand merge semantics or updates surprise you.
  • Series. series: [{ type: 'line'|'bar'|'pie'|'scatter'|'candlestick'|'graph'|'heatmap'|'sankey'|..., data, encode }]. Multiple series share axes.
  • Dataset + encode. dataset: { source: [[...rows]] } + encode: { x: 'date', y: 'value' } — separates data from mapping; multiple series can share one dataset.
  • Transforms. dataset: [{ source }, { transform: { type: 'filter', config: {...} } }] — filter/sort/aggregate declaratively before rendering.
  • Visual mapping. visualMap (continuous/piecewise) maps data values → color/size/opacity. Choropleths and heatmaps depend on it.
  • Components. dataZoom (inside/slider zoom), toolbox (save-as-image, data view), brush (selection), timeline (animated time playback), graphic (custom overlays).
  • Renderer. Canvas (default, fast) vs SVG ({ renderer: 'svg' } — crisper, accessible DOM, slower for huge data).
  • Large data. series-large strategies: sampling: 'lttb', progressive rendering, dataZoom windowing. ECharts handles millions of points with the right settings.

Practical workflow

1. Setup.

import * as echarts from 'echarts/core';
import { LineChart, BarChart } from 'echarts/charts';
import { GridComponent, TooltipComponent, DataZoomComponent, DatasetComponent } from 'echarts/components';
import { CanvasRenderer } from 'echarts/renderers';
echarts.use([LineChart, BarChart, GridComponent, TooltipComponent, DataZoomComponent, DatasetComponent, CanvasRenderer]);

(Tree-shaken imports like Chart.js; or import * as echarts from 'echarts' for everything.)

2. Dataset-driven chart.

chart.setOption({
  dataset: { source: [
    ['date', 'revenue', 'costs'],
    ['2026-01', 120, 80], ['2026-02', 150, 90], ...
  ]},
  xAxis: { type: 'category' }, yAxis: {},
  tooltip: { trigger: 'axis' },
  dataZoom: [{ type: 'inside' }, { type: 'slider' }],
  series: [
    { type: 'line', encode: { x: 'date', y: 'revenue' }, smooth: true, sampling: 'lttb' },
    { type: 'bar', encode: { x: 'date', y: 'costs' } },
  ],
});

3. Updates. setOption with changed data merges by default — efficient. For full replacement (new series set), pass { notMerge: true }.

4. Events. chart.on('click', params => ...) — drill-downs, cross-chart filtering (dispatch actions to other charts: chart.dispatchAction({ type: 'highlight', ... })).

5. Responsive. chart.resize() on container resize (ResizeObserver); media queries in option for breakpoint-specific configs.

6. Dispose. chart.dispose() on unmount — ECharts holds DOM listeners and timers.

Common pitfalls

  • Merge vs replace confusion. setOption merges by default — stale series linger when data shape changes. Use { notMerge: true } when the structure changes, merge for data updates.
  • Forgetting dispose. Leaked charts accumulate listeners/timers in SPAs. Dispose in cleanup.
  • Huge data without sampling. Default rendering of 1M points will hang. sampling: 'lttb', progressive, or server-side aggregation + dataZoom.
  • Category axis with massive categories. 10k categories on an axis = unreadable. Aggregate, or use value/time axes.
  • Tooltip trigger mismatch. trigger: 'axis' for multi-series comparison; trigger: 'item' for pies/scatter. Wrong trigger = confusing tooltips.
  • No resize handling. Charts don't auto-resize with containers. ResizeObserver → chart.resize().
  • Over-customizing via graphic. The graphic component is powerful but imperative-ish; prefer declarative series/components first.
  • Accessibility afterthought. Canvas charts need aria-label on the container + a data table/summary alternative. Consider SVG renderer for screen-reader-navigable charts.
  • Timezone bugs. Time axes with mixed UTC/local data shift points. Normalize to one zone (usually UTC) before feeding ECharts.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Master 1Password: vaults, Watchtower, passkeys, SSH agent, CLI, and family/team administration. Use when getting full value from 1Password personally or administering it for others.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

Create 3D visuals with modeling, texturing, lighting, rendering, and optimization for web and product.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

Create 3D web experiences: scene setup, models, materials, lighting, animation, scroll-driven scenes, and performance budgets. Use when adding 3D to websites beyond basic demos.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

Writing abstracts that get papers read — structured content, the 5-sentence core, and journal-specific constraints.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

Learn effectively from courses and academies: choosing programs, studying actively, and converting courses into skills. Use when investing time/money in structured learning.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

Audit designs for accessibility with WCAG checklists covering color, type, focus, motion, and content.

한국어 요약은 준비 중입니다. 원문 설명을 표시하고 있습니다.

aicodedecode/awesome-muse-skills252026년 10월 10일 업데이트

aicodedecode의 스킬 모두 보기

이 스킬의 문제 신고