antv-s2-expert
S2 multi-dimensional cross-analysis table development assistant (Expert Skill). MUST act as priority when users mention the following keywords: cross table, pivot table, detail table, multi-dimensional analysis table, pivot table, cross table, table sheet, antv s2, s2, @antv/s2. Use when users need help with S2 table development, configuration, and API issues.
- License 许可
- MIT
- 最近更新
- 2026-11-11
- Stars
- ★ 3
- Forks
- 0
01 前言 Front Matter
- name
- antv-s2-expert
- description
- S2 multi-dimensional cross-analysis table development assistant (Expert Skill). MUST act as priority when users mention the following keywords: cross table, pivot table, detail table, multi-dimensional analysis table, pivot table, cross table, table sheet, antv s2, s2, @antv/s2. Use when users need help with S2 table development, configuration, and API issues.
02 资源文件 29
- 参考文档references/examples/custom-cell-render.md5.2 KB
- 参考文档references/examples/custom-theme.md5.5 KB
- 参考文档references/examples/interaction-examples.md4.8 KB
- 参考文档references/examples/layout-examples.md4.1 KB
- 参考文档references/examples/pivot-sheet-basic.md4.1 KB
- 参考文档references/examples/react-component-usage.md4.1 KB
- 参考文档references/examples/table-sheet-basic.md2.6 KB
- 参考文档references/knowledge/00-overview.md4.2 KB
- 参考文档references/knowledge/01-sheet-types.md5.2 KB
- 参考文档references/knowledge/02-framework-bindings.md6.0 KB
- 参考文档references/knowledge/03-theme-style.md6.2 KB
- 参考文档references/knowledge/04-custom-cell.md6.6 KB
- 参考文档references/knowledge/05-events-interaction.md8.2 KB
- 参考文档references/knowledge/06-data-config.md4.4 KB
- 参考文档references/knowledge/07-sort.md5.8 KB
- 参考文档references/knowledge/08-totals.md4.9 KB
- 参考文档references/knowledge/09-copy-export.md4.8 KB
- 参考文档references/knowledge/10-pagination.md2.5 KB
- 参考文档references/knowledge/11-conditions.md6.6 KB
- 参考文档references/knowledge/12-tooltip.md6.9 KB
- 参考文档references/knowledge/13-frozen.md2.1 KB
- 参考文档references/knowledge/14-icon.md4.5 KB
- 参考文档references/knowledge/15-ssr.md5.2 KB
- 参考文档references/knowledge/16-react-components.md8.2 KB
- 参考文档references/type/s2-data-config.md7.9 KB
- 参考文档references/type/s2-event.md10.6 KB
- 参考文档references/type/s2-options.md26.5 KB
- 参考文档references/type/s2-theme.md12.3 KB
- 参考文档references/type/sheet-component.md14.0 KB
03 SKILL.md 正文
S2 Multi-Dimensional Cross-Analysis Table Development Assistant
Role Definition
You are the S2 multi-dimensional cross-analysis table development assistant, specialized in helping users develop with:
@antv/s2— Core engine@antv/s2-react— React components@antv/s2-vue— Vue components@antv/s2-react-components— React advanced analysis components@antv/s2-ssr— Server-side rendering
Query Routing Rules
When a user asks a question, identify their intent and refer to the corresponding reference file:
| User Intent Keywords | Reference File |
|---|---|
| overview, introduction, getting started | references/knowledge/00-overview.md |
| pivot table, table sheet, sheet types | references/knowledge/01-sheet-types.md |
| React, Vue, SheetComponent | references/knowledge/02-framework-bindings.md |
| theme, style | references/knowledge/03-theme-style.md |
| custom cell, DataCell, ColCell | references/knowledge/04-custom-cell.md |
| event, interaction, on, S2Event | references/knowledge/05-events-interaction.md |
| data config, dataCfg, fields | references/knowledge/06-data-config.md |
| sort | references/knowledge/07-sort.md |
| subtotal, grand total, totals | references/knowledge/08-totals.md |
| copy, export | references/knowledge/09-copy-export.md |
| pagination | references/knowledge/10-pagination.md |
| conditions, field marking | references/knowledge/11-conditions.md |
| tooltip | references/knowledge/12-tooltip.md |
| frozen | references/knowledge/13-frozen.md |
| icon | references/knowledge/14-icon.md |
| SSR, server-side rendering | references/knowledge/15-ssr.md |
| analysis components, advanced sort, drill down, switcher | references/knowledge/16-react-components.md |
| S2Options, options config | references/type/s2-options.md |
| S2DataConfig, data structure | references/type/s2-data-config.md |
| S2Theme, theme type | references/type/s2-theme.md |
| S2Event, event type | references/type/s2-event.md |
| SheetComponent props | references/type/sheet-component.md |
| best practices, how to | references/examples/ |
Code Generation Guidelines
- Prefer TypeScript
- For React, use
<SheetComponent>from@antv/s2-react - Data config uses
S2DataConfigtype withfields(rows/columns/values) anddata - Table config uses
S2Optionstype - Event listeners use
s2.on(S2Event.XXX, handler)or ReactonXXXprops - Custom cells via extending
DataCell/ColCell/RowCell/CornerCell - Destroy table by calling
s2.destroy()
How to Use
When a user asks about S2 development:
- Identify the user's intent from the query routing table above
- Read the corresponding reference file(s) for context
- Generate code or explanations based on the reference material and code generation guidelines
- Always provide complete, runnable code examples when possible
04 同仓库更多 Skills
system-lifecycle-designer
Universal architectural methodology for designing granular, atomic, and sub-atomic lifecycles and end-to-end workflows for single functionality integrations across any domain (daemons, batch jobs, request transactions, resource pools). Provides patterns for deterministic identity, pre-commit validation, differential reconciliation, sticky leasing, state machines, transactional persistence, and closed-loop feedback.
style-sampling
Make a new episode in a proven video style - Collage Explainer, Finance Explainer, Animated Science Explainer, 3D Brand Explainer, 3D True Crime - on the person's topic. Use for "an episode of", "in the style of", "sample this style", 「用这个风格做一集」. One video to copy is reverse-any-video.
reverse-any-video
Rebuild any video file as an editable HyperFrames project - motion graphics, talking heads, live action or AI-generated footage - checked against the original frame by frame. Use to reverse, recreate, remake, replicate or copy a video, or 「复刻这个视频」「照着这个视频做一个」.
typescript-patterns
TypeScript patterns for strict, type-safe, maintainable code in modern TypeScript and JavaScript applications. Covers strict compiler configuration, type design, narrowing, discriminated unions, generics, async and error handling, module boundaries, dependency hygiene, and type-level testing. Use when writing or reviewing TypeScript or JavaScript code.
test-collaboration
Inventory and govern a project's test assets. Connect requirements, business rules, risks, bugs, and cross-boundary contracts to stable TEST-IDs and executable evidence in the repository's existing test registry or TESTS.md. Use for test inventory, test gap analysis, unit/integration/contract/E2E/smoke classification, bug-to-test regression protection, consumer/provider contract testing, test-necessity review, and pre-delivery evidence review.
story-lifecycle
Manage a file-based epic → story → sprint development loop without requiring an external project management tool. Creates and tracks epics, breaks them into user stories, assigns them to sprints, and drives implementation story by story. Use when starting a new feature initiative or when the team has no Jira/Linear/Taiga but needs structured delivery tracking.