angular infinite $digest loop error solution

I used ui.router and someday i found out
error console show me this error

10 $digest() iterations reached. Aborting!
Watchers fired in the last 5 iterations: [["fn: $locationWatch; newVal: 32; oldVal: 31"],["fn: $locationWatch; newVal: 33; oldVal: 32"],["fn: $locationWatch; newVal: 34; oldVal: 33"],["fn: $locationWatch; newVal: 35; oldVal: 34"],["fn: $locationWatch; newVal: 36; oldVal: 35"]]

and I debug for whole day and gave up.

after debugging, I seached on internet and many people face with this problem.

and I finally fix the error

Before if I used location.href='#/xxxxxx'
and changed is $location.path(realpath);

Comments

Popular posts from this blog

Project euler 169 found clue

Floyd-Warshall's algorithm