Eliav2 / react-xarrows

Draw arrows (or lines) between components in React!
https://codesandbox.io/embed/github/Eliav2/react-xarrows/tree/master/examples?fontsize=14&hidenavigation=1&theme=dark
MIT License
584 stars 75 forks source link

TypeError on showHead={false} and animateDrawing={true} #106

Open JosDaw opened 3 years ago

JosDaw commented 3 years ago

Hello, thanks for the helpful package! I think I'm encountering an unexpected bug.

Bug: Rendering arrows with showHead={false} and animateDrawing={true} results in a TypeError.

Details: Crash report shows TypeError: headRef.current is null

To Reproduce

<Xarrow
    start={`circle2`}
    end={`circle3`}
    showHead={false}
    animateDrawing={true}
    strokeWidth={1}
  />
cristopheram commented 2 years ago

Any possible fix on this? @Eliav2 Thanks in advance