@particle-academy/fancy-echarts 1.2.1 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/docs/EChart3D.md +7 -1
- package/package.json +10 -5
package/README.md
CHANGED
|
@@ -15,13 +15,17 @@ pnpm add @particle-academy/fancy-echarts echarts
|
|
|
15
15
|
yarn add @particle-academy/fancy-echarts echarts
|
|
16
16
|
```
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
`echarts` is a peer dependency — install it alongside fancy-echarts so you control the version and avoid bundling two copies if other parts of your app already use echarts.
|
|
19
|
+
|
|
20
|
+
For 3D charts (globe, surface, scatter3D, bar3D), also install `echarts-gl`:
|
|
19
21
|
|
|
20
22
|
```bash
|
|
21
23
|
npm install echarts-gl
|
|
22
24
|
```
|
|
23
25
|
|
|
24
|
-
**Peer dependencies:** `react >= 18`, `react-dom >= 18`, `echarts >= 5.5`
|
|
26
|
+
**Peer dependencies:** `react >= 18`, `react-dom >= 18`, `echarts >= 5.5`, `echarts-gl >= 2.0` (optional, only needed for 3D)
|
|
27
|
+
|
|
28
|
+
> **Breaking change in 2.0** — `echarts` and `echarts-gl` moved from regular dependencies to peer dependencies. Upgrading from 1.x? Run `npm install echarts` (and `echarts-gl` if you use 3D charts) once.
|
|
25
29
|
|
|
26
30
|
## Quick Start
|
|
27
31
|
|
package/docs/EChart3D.md
CHANGED
|
@@ -8,7 +8,13 @@
|
|
|
8
8
|
import { EChart3D } from "@particle-academy/fancy-echarts";
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
`echarts-gl` is
|
|
11
|
+
`echarts-gl` is an **optional peer dependency** as of fancy-echarts 2.0 — install it alongside fancy-echarts when you use 3D charts:
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
npm install echarts-gl
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
The GL engine is dynamically loaded on first render of an `EChart3D`, so consumers that never use 3D charts pay nothing.
|
|
12
18
|
|
|
13
19
|
## Base Component
|
|
14
20
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@particle-academy/fancy-echarts",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "React component library wrapping Apache ECharts with typed components for every chart type",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -45,15 +45,20 @@
|
|
|
45
45
|
],
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"react": "^18.0.0 || ^19.0.0",
|
|
48
|
-
"react-dom": "^18.0.0 || ^19.0.0"
|
|
48
|
+
"react-dom": "^18.0.0 || ^19.0.0",
|
|
49
|
+
"echarts": "^5.5.0",
|
|
50
|
+
"echarts-gl": "^2.0.0"
|
|
49
51
|
},
|
|
50
|
-
"
|
|
51
|
-
"echarts":
|
|
52
|
-
|
|
52
|
+
"peerDependenciesMeta": {
|
|
53
|
+
"echarts-gl": {
|
|
54
|
+
"optional": true
|
|
55
|
+
}
|
|
53
56
|
},
|
|
54
57
|
"devDependencies": {
|
|
55
58
|
"@types/react": "^19.0.0",
|
|
56
59
|
"@types/react-dom": "^19.0.0",
|
|
60
|
+
"echarts": "^5.6.0",
|
|
61
|
+
"echarts-gl": "^2.0.9",
|
|
57
62
|
"react": "^19.0.0",
|
|
58
63
|
"react-dom": "^19.0.0",
|
|
59
64
|
"tsup": "^8.5.0",
|