This is a late answer, but I had the same problem, but the answer was different.
In my case, in my code there was a link to sourceURL:
When this Javascript file is minimized and downloaded by the browser, it usually tells Chrome Dev Tools where the incomplete version is.
However, if you are debugging an incomplete version and this line exists, Chrome Dev Tools displays this sourceURL path instead of the "normal" path.
For example, if you work locally on a web server, then on the Sources tab in Chrome Dev Tools, the path to the specified JS file will be http://localhost/Scripts/test.js
If test.js has this at the bottom
then breakpoints will only work if the path to the /Scripts/test.js file is not the full URL http://localhost/Scripts/test.js
In Chrome 38, following my example above, if you look at the Sources tab, each file starts with http://localhost/ , so when you click on test.js, Chrome loads http://localhost/Scripts/test.js
You can put all the breakpoints you need into this file, and Chrome will never reach any of them. If you place a breakpoint in your JS before it calls any function in test.js and then enter that function, you will see that Chrome opens a new tab, whose path is /Scripts/test.js . Placing breakpoints in this file will stop program execution.
When I got rid of the @sourceURL line from the JS file, everything worked fine again (i.e. the way you expect).
Stephen Nov 05 '14 at 18:27 2014-11-05 18:27
source share