Skip to content
This repository was archived by the owner on Jun 13, 2025. It is now read-only.
This repository was archived by the owner on Jun 13, 2025. It is now read-only.

Disconnect FlattenedNodesObserver on disconnectedCallback #6

Description

@mperktold

The FlattenedNodesObserver created in the constructor is never disconnected:

The docs suggest that this should be done:
https://polymer-library.polymer-project.org/3.0/api/utils/flattened-nodes-observer

Otherwise, I suspect this leads to memory leaks. In our application, we saw several objects retained by detached DOM nodes, and for many of them, this component shows up in their retainers. That's of course not a proof that this component is the root cause, but since there is this thing going on with the FlattenedNodesObserver, I can't rule it out either.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions