Skip to content

Memory leak in updateDOMListeners and updateComponentListeners #6931

@fenduru

Description

@fenduru

Version

2.5.2

Reproduction link

https://jsfiddle.net/opzzsudp/

Steps to reproduce

  1. Create a Vue instance that has a reference to a large object in its data
  2. Render either a component or an element with any event handler
  3. Destroy the Vue instance, remove its element, null out its reference

What is expected?

The Vue instance and the references it contains should be freed for garbage collection

What is actually happening?

The target variables here or here hang onto references and prevent garbage collection


I have a fix ready for this and will be filing a PR shortly

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