Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Responses are not intercepted on page reload #161

Open
churixho opened this issue Aug 30, 2018 · 6 comments
Open

Responses are not intercepted on page reload #161

churixho opened this issue Aug 30, 2018 · 6 comments
Assignees

Comments

@churixho
Copy link

churixho commented Aug 30, 2018

My SPA site is built using ReactJS + Redux + react router.
Let's say we have page A whichs load a.json and page B which loads b.json

Case 1: Go to page A; intercept a.json; then refresh the page
Results: a.json is not intercepted

Case 2: Go to page A; intercept b.json; then go to page B
Results: b.json is intercepted successfully

Expected behaviour: Response could be intercepted upon page refresh

@revathskumar
Copy link
Contributor

@churixho Chrome/Firefox?

@churixho
Copy link
Author

churixho commented Aug 30, 2018

Problem occured in both Firefox and Chrome

@churixho
Copy link
Author

It appears to me that the this is due to race condition. When I delay the axios in my site (i.e. the loading of a.json in the example) for 2 seconds, the result could be interruped.

@amitmbee
Copy link
Contributor

@churixho Yes, the issue here is that the the web page gets the data from axios before Interceptor can inject a script. We are working towards a fix for this.

@therisingindian
Copy link

I'm also waiting for the capability to intercept response on page reload.

@quinncomendant
Copy link

I'm using Interceptor to debug an angular page, and need to intercept XHR requests run during page load. I too notice that Interceptor can't intercept this when reload the page.

@akshaysasidrn akshaysasidrn self-assigned this Oct 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants