hustcc
hustcc
@hwjom 看起来代码问题不大,方便在 PR 描述中做一些修改前后的对照 gif 嘛?
换成其他的地址了?为啥需要用这个?
官网有案例代码,使用标签即可。
- related https://github.com/antvis/G2/pull/6515#issuecomment-2514147671
> My project is having an error : Attempted import error: 'nelderMead' is not exported from 'fmin' (imported as 'nelderMead') in @antv. Please merge this MR for fix bug above....
这是在学习源码吗?建议以解决几个 issue,或者有目标的看源码,更实用。 这个 pr 看来是很难被合并,因为内容比较杂,先关闭了,不然这边会收到提醒。
时间线比较久了,也建议大家升级到新版本。
Q1 占位,需要调研一下。 核心逻辑是,通过监听 plot 事件,然后针对事件去计算 scale.domain 的大小,然后重新 render。 ```ts import { Chart } from '@antv/g2'; const chart = new Chart({ container: 'container', theme: 'classic', autoFit: true, }); chart .point() .data({...
Q2:G2 中如何实现 在折线图中增加垂直的标注尺,标注尺可以拖拽。分别支持单标尺和双标尺 标尺线可使用 标注去实现,参考 [DEMO](https://g2.antv.antgroup.com/examples/annotation/line/#interval-mean-line),但是拖拽的能力,需要外部监听事件去实现。  ```ts chart.on('lineY:click', (e) => { console.log(e); }) ```
G6 和 X6 是不同的库。 - G6 的自定义节点:https://g6.antv.antgroup.com/manual/element/node/react-node - X6 的自定义节点:https://x6.antv.antgroup.com/tutorial/intermediate/react