antvis/G6

【v5.0.1】stopLayout后setData&render,还是会重新布局 #5850

uhobnil posted onGitHub

Describe the bug / 问题描述

stopLayout后调用setData&render重新设置数据,还是会layout

v4版本destroyLayout后再changeData,不会layout

No response

Steps to Reproduce the Bug or Issue / 重现步骤

No response

G6 Version / G6 版本

🆕 5.x

Operating System / 操作系统

macOS

Browser / 浏览器

Chrome

Additional context / 补充说明

No response


如果不希望执行布局,可以使用 draw 方法替代 render 方法

posted by Aarebecca 11 months ago

如果不希望执行布局,可以使用 draw 方法替代 render 方法

业务需求是可以随意切换某个节点的显示/隐藏,draw后再显示,坐标变会为[0,0]

只能自己记录节点隐藏前的坐标吗,有没有其他方法

posted by uhobnil 11 months ago

Fund this Issue

$0.00
Funded

Pull requests