OiO.lk Community platform!

Oio.lk is an excellent forum for developers, providing a wide range of resources, discussions, and support for those in the developer community. Join oio.lk today to connect with like-minded professionals, share insights, and stay updated on the latest trends and technologies in the development field.
  You need to log in or register to access the solved answers to this problem.
  • You have reached the maximum number of guest views allowed
  • Please register below to remove this limitation

How to breakpoint before new tab is opened by React?

  • Thread starter Thread starter nlblack323
  • Start date Start date
N

nlblack323

Guest
Normally this is done by checking the beforeunload event listener breakpoint from the sources tab in Chrome devtools. However, when I try to click the apply button here (or any other glassdoor easy apply button) it keeps being opened and the breakpoint doesn't work. The reason why I need a breakpoint is to locate the code that generates a magic url that appears in the opened tab.

One way of seeing the magic url in the network tab is by refreshing the new tab, then 2 document requests will show up. I'm interested in the second one which generates a url that looks like this:

https://smartapply.indeed.com/beta/indeedapply/resumeapply?...

which has a questions param among many other magic params which source is unknown.

I tried checking all load breakpoint event listeners but neither works, the tab just keeps being opened uninterrupted.

<p>Normally this is done by checking the <code>beforeunload</code> event listener breakpoint from the sources tab in Chrome devtools. However, when I try to click the apply button <a href="https://www.glassdoor.com/job-listi...IC1153524_KO0,18_KE19,41.htm?jl=1009274511698" rel="nofollow noreferrer">here</a> (or any other glassdoor easy apply button) it keeps being opened and the breakpoint doesn't work. The reason why I need a breakpoint is to locate the code that generates a magic url that appears in the opened tab.</p>
<p>One way of seeing the magic url in the network tab is by refreshing the new tab, then 2 document requests will show up. I'm interested in the second one which generates a url that looks like this:</p>
<p><a href="https://smartapply.indeed.com/beta/indeedapply/resumeapply?.." rel="nofollow noreferrer">https://smartapply.indeed.com/beta/indeedapply/resumeapply?..</a>.</p>
<p>which has a <code>questions</code> param among many other magic params which source is unknown.</p>
<p>I tried checking all load breakpoint event listeners but neither works, the tab just keeps being opened uninterrupted.</p>
 

Latest posts

Top