How to view functions called from button click to a request in Chrome Dev Tools?

Viewed 835

How can I see which functions and in what order were called after I clicked on a button, before a network request is sent? Should I pause with a mouse click breakpoint or XHR/fetch breakpoint? I want to find the origin of certain variables (in this case, request headers and parameters) how were they structured or generated when passed in a request

2 Answers

enter image description here

The Call Stack shows the Chain of the call until the breakpoint

enter image description here

Also hovering on the initiator of the request in the network panel shows the call stack

You can use the initiator tab if you are looking for the callstack which triggered the request. enter image description here

Related