Angular memory leak

I am using angular 1.2.6 and there is a memory leak problem when switching views that are controlled by Angular.

The DOM does not appear to be released when switching views.

I have studied very deeply how to resolve a memory leak in angular, but the problem is still happening.

You can see the “separate DOM” using the Chrome profile tool.

A very simple application here: http://myclients.azurewebsites.net/#/

Also got this problem?

You can refer to this question posed by Alex Shnayder : http://www.marshut.com/iknntu/leaking-scope-when-method-on-scope-references-scope-itself.html

This is exactly the same problem with me.

+4
source share
1

. -, , . , , .

app.js

//app.js
var myclients = myclients || {};
myclients.app = angular.module("myclients", ["ngRoute", "upidamodule"]);

var myclients . angular.

, , , GC, , 2 . - angular, - window - var myclients.

, , $scope, $parent .. .., / .

GC Chrome - Chrome - .

. , jQuery

0

Source: https://habr.com/ru/post/1532401/


All Articles