Skip to content

[Bug] Tooltip dispose memory leaks! #21083

@seaheart

Description

@seaheart

Version

5.6.0

Link to Minimal Reproduction

https://echarts.apache.org/examples/zh/editor.html?c=line&lang=ts

Steps to Reproduce

  1. Set tooltip formatter to function, like: () => dom string
  2. Destory and recreate chart by operate setOption frequently
  3. Open chrome and check memory then see detached dom nodes

Current Behavior

Image

Expected Behavior

no tooltipHtmlContent leaks

Environment

- OS:
- Browser:
- Framework:

Any additional comments?

v5.6.0

Image

in tooltipHTMLContent dispose function, there has not remove the events handler:onmouseenter、onmousemove、onmouseleave, that may case memory leaks!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions