Skip to content

Feature request: Add a destroy method to the dataset #831

@AlexDM0

Description

@AlexDM0

Hi guys, I've been working on a project with the vis-timeline and the dataset in a react environment. When the component gets removed, I'd like to destroy the datasets along with the timeline.

The timeline (and other vis components) have a destroy method, which removes all data and event listeners.

Sure, the timeline destroy will remove the event listeners it has on the dataset. If I remove the datasets first (clear(), flush()?) first, this would trigger a redraw of the timeline, which is also in the process of being destroyed. This introduces a race condition I could solve, but ideally would want to sidestep by a destroy method on the dataset itself.

What do you guys think?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions