Skip to content

Modifier cleanup needs improvement #149

@lukemelia

Description

@lukemelia

Currently, the modifier calls floating-ui's autoUpdate in its modify method, which will run whenever an input changes. The method captures the cleanup function that autoUpdate returns and registers it as a destructor, but that can still result in multiple autoUpdates being registered.

Instead, the modifier should capture the last cleanup method and call it at the beginning of the modify method, if present. (There will be none captured the first time the modifier instance runs.)

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