Determining why Firebug won't be a gray / green line

I'm tearing my hair out of here because of Firebug's apparent tendency to abandon breakpoints in critical sections, where it would be really very useful to skip the code to see what happens. I read elsewhere that Firebug will not hit the breakpoint if the line number is not the correct color: it was green, but lately I notice that this is apparently the difference between light gray and dark gray, where the light gray lines are those that Firebug won't break.

I am looking for any suggestions on how to get Firebug to recognize that it should be able to split the string. Often, he refuses to mark breakpoints for ten or twenty lines in a row, as if he suddenly got confused in the parsing of a function and simply gave up until the function ended. In some cases, just commenting on one line (and then reloading, of course) makes Firebug suddenly recognize the rest of the function, but without any rhymes or reasons that I can see, even to the extent that just adding something as harmless as extra the semi-colon makes him return to not recognizing lines again. In some cases, it seems that the do / while loops confuse it, but even in a function without such a loop, I am currently having problems.

I already tried all the other things that I could find in other threads, for example, resetting everything, restarting the browser, using the latest version, etc.

Update: in one case, I was able to make Firebug recognize the lines by changing:

do { ... } while (condition) 

to

 while (1) { ... if (!(condition)) break } 

Firefox 23 / Firebug 1.11.4

Update. It seems that whenever I find such a section of code, I can get away from the problem by creating a new empty javascript file (adding a link to the HTML file) and moving the affected function to this file, Suddenly the lines are green (now it turns green again, not I know why ...)

+4
source share

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


All Articles