react-d3-tree icon indicating copy to clipboard operation
react-d3-tree copied to clipboard

baseNodes translated to infinite => `transform="translate(2744000,280)"`

Open baptisteArno opened this issue 5 years ago • 1 comments

Are you reporting a bug, or opening a feature request?

A bug

What is the actual behavior/output?

I'm computing a tree on component load but it is weirdly rendered : CleanShot 2020-06-11 at 15 17 10

What is the behavior/output you expect?

CleanShot 2020-06-11 at 15 20 45

I succeeded in having the expected behavior because I stringified what my function computed for the tree and just paste it in my code. I made sure the 2 tree objects are equal (with deep-equal lib). What could be wrong here?

What version of react-d3-tree are you using?

1.16.1

baptisteArno avatar Jun 11 '20 13:06 baptisteArno

UPDATE

if my function returns return JSON.parse(JSON.stringify(newTree)); it succeeds rendering the tree

if it returns return newTree then it fails.

baptisteArno avatar Jun 11 '20 13:06 baptisteArno