Skip to main content
edited tags
Link
Xan
  • 77.9k
  • 18
  • 198
  • 219
Source Link
John Hoffman
  • 18.8k
  • 21
  • 61
  • 84

Go to source code line in Chrome dev tools extension?

I want to make a dev tools Chrome extension that lets the user go to specific points in the page's source code (whenever the page's source code calls some global function foo that I inject into the page via an extension content script).

I can get a stack trace by having function foo throw an exception and then catch it.

But how can I tell Chrome dev tools to go navigate to a certain line in the source code? Is there an API call for that?