G
G copied to clipboard
Marker 文档缺失
同求marker 文档
同求
加1
- 可以参考以下示例:
import { Canvas } from "@antv/g";
const canvas = new Canvas({
containerId: "root",
width: 400,
height: 400
});
const group = canvas.addGroup();
const circle = group.addShape("marker", {
attrs: {
x: 50,
y: 100,
r: 10,
lineWidth: 2,
stroke: "blue",
fill: "red"
symbol: "circle" // square, diamond, triangle, triangle-down,
}
});
canvas.draw();
- 完整示例可以参考: https://codesandbox.io/s/g-marker-demo-ezsuh
- G 4.0 会提供官网,包含使用教程、API 文档、Demo,可以关注这个 #172.
@dengfuping 能给出具体4.0发布时间吗?
@cookHu 已经有 beta 版发布了,4.0 不同的渲染模式拆成了不同的包
-
Canvas 版: @antv/g-canvas
-
SVG 版: @antv/g-svg
-
4.0 的官网和完整文档要等 11.22 才能放出了。
- Marker 文档可见 https://g.antv.vision/zh/docs/api/shape/marker