Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Force chrome to refresh a page while debugging with breakpoints

If I have a breakpoint in a loop or frequent interval I can't refresh chrome without forcing a reload with ctrl-r.

Hitting F5/clicking the refresh button will do a normal refresh, loading just the modified content, unless the debugger has paused on a breakpoint in which case the debugger continues. Holding/spamming F5 just cycles through breakpoints and I can't refresh the page after spotting a bug and making code changes. I'd prefer not to do a full reload (ctrl-r) because I have images and other content that get cached and don't need to be re-downloaded.

One solution is to close the debugger, refresh and then open the debugger. However, the JS then gets a chance to run before the debugger is back up. I then have to refresh again so the JS runs from the beginning.

Has anyone found a workaround?

It could be just me, but I frequently want to make changes to my code and debug it at the same time.


  • Refresh: F5

  • No, actually refresh: hammer+F5?

like image 502
jozxyqk Avatar asked Mar 09 '14 07:03

jozxyqk


People also ask

How do I automatically refresh a page in chrome?

Google Chrome (version 57.0.Click the three vertical dots on the upper-right corner and select Settings. Select Extensions and click Get more extensions at the bottom of the page. Search for the Auto Reload Page Extension and click Add to Chrome. On the pop-up notification, click Add Extension.

How do I refresh inspect in chrome?

Right-click anywhere on the page + choose Inspect (Google Chrome) or Inspect element (other browsers) Click on Console tab in the window that appears. Reload the page.

How do I refresh a page in developer tools?

Press F12 and open the developer tools. On the refresh button, on the top left of the browser window, do a right click.

How do I bypass paused Debugger in chrome?

Did you know that you could right click on any line of Javascript code in Google Chrome Developer Tools, and select “Never Pause Here” to undo breakpoints at runtime? This is different from disabling a breakpoint. This actually forces code NOT to stop on a particular line.


1 Answers

What works for me is to CMD + R (I'm on OS X) then F8.

It seems that reload is done only after you pass the current breakpoint.

like image 148
avetisk Avatar answered Oct 14 '22 07:10

avetisk