Bug Tracker

Opened 5 years ago

Closed 5 years ago

#15205 closed feature (migrated)

No way to globally clean up data

Reported by: m_gol Owned by:
Priority: low Milestone: 2.next
Component: data Version: 2.1.1
Keywords: Cc: dmethvin, Rick Waldron
Blocked by: Blocking:

Description

When an element data is leaked (for example because it was detached/off-DOM and we lost reference to it) there is no way to get rid of its data. This matters in tests run in watch mode as leaks can accumulate & crash the browser.

The only alternative now seems to be initializing jQuery from scratch when we desire a clean environment. This is a little difficult now due to the fact that jQuery doesn't expose any initializing function so the lib would have be loaded once again (which, again, is not so easy/natural in many test frameworks).

Angular 1.3 betas were recently switched to use jQuery 2.1 instead of 1.x and this problem has arisen; see: https://github.com/angular/angular.js/issues/8532

Change History (4)

comment:1 Changed 5 years ago by m_gol

*If* we end up attaching data directly to nodes the problem may mostly go away. Mostly since we still may have leftover data from special events etc.

comment:2 Changed 5 years ago by timmywil

Status: newopen

comment:3 Changed 5 years ago by m_gol

Milestone: None2.next

Let's see how 2.2 data approach fares.

comment:4 Changed 5 years ago by m_gol

Resolution: migrated
Status: openclosed
Note: See TracTickets for help on using tickets.