Firefox crash using angular (Troll troll-collector?)

---- EDIT question was long and hard to understand ------

Here is a working example: http://codepen.io/anon/pen/Mwapgb WARNING: This will do firefox CRASH !, if you dare, click about 500 times on any div (I suggest using a tool to simulate it. Rip mouse)

But this is http://codepen.io/anon/pen/eNNqde Wont make firefox crash

What is the difference:

function GetDateFromDatetimePython(stringdate){ // IT CRASH var partieDate = stringdate.split(' '); var ymd = partieDate[0].split('-'); var hms = partieDate[1].split(':'); return new Date(Date.UTC(ymd[0],ymd[1]-1,ymd[2],hms[0],hms[1],hms[2],0)); } function GetDateFromDatetimePython(stringdate){ // IT DON'T var partieDate = stringdate.split(' '); var tmp = partieDate[0]; // add this var tmp2 = partieDate[1]; // add this var ymd = tmp.split('-'); // change this var hms = tmp2.split(':'); // change this return new Date(Date.UTC(ymd[0],ymd[1]-1,ymd[2],hms[0],hms[1],hms[2],0)); } 

I'm going crazy. What is wrong with the first practice?

Ok, silly to do 3 splits, I could combine in 1. Whenever. WHY does it explode firefox, Why Chrome and IE are not affected?

+5
source share
1 answer

You may have fallen into some sort of endless loop or created process that involves heavy processing that depletes all the memory available to your browser.

0
source

All Articles