@json-render-echarts/schemas
v1.1.1
Published
Zod schemas for ECharts catalog components
Downloads
433
Readme
@json-render-echarts/schemas
Zod schemas for Apache ECharts components in the json-render ecosystem.
Why use this?
ECharts has thousands of properties and deeply nested structures. These schemas provide a simplified, type-safe abstraction that is:
- AI-Friendly: Reduces hallucination by limiting available properties.
- Type-Safe: Provides full TypeScript types and Zod validation.
- Standardized: Aligned with official ECharts top-level options.
Installation
npm install @json-render-echarts/schemasIncluded Schemas
- BaseChartSchema: Common options like title, legend, grid, tooltip, and toolbox.
- BarChartSchema
- LineChartSchema
- AreaChartSchema
- PieChartSchema
- ScatterChartSchema
Usage
import { BarChartSchema } from '@json-render-echarts/schemas';
// Use for catalog generation
const echartsCatalog = {
BarChart: BarChartSchema,
};License
MIT
