Improve initiator column to show the requesting javascript module
Reported by
jase.wil...@gmail.com,
Nov 1 2017
|
||||||
Issue descriptionUserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.75 Safari/537.36 Steps to reproduce the problem: 1. Navigate to https://www.bbc.co.uk/radio2 2. Open dev tools, and go to the Network tab 3. Inside the initiator column many rows show require.js:1958 See screenshot What is the expected behavior? I would love to see something like require.js:1958:app.js or [libraryLoader:actualJSModule] Chrome would need to somehow get the dependancy tree from require then add the calling module to the initiator tab. This *should* hopefully be possible What went wrong? Seeing require.js:1958 is pretty useless to a developer, it just goes into the require black box and doesn't help me in finding out what require module pulled in the next dependancy? It would be really cool if we're able to see what frontend module pulled in the next module in the dependancy tree. Right now its pretty hard to work this out. Did this work before? N/A Chrome version: 62.0.3202.75 Channel: stable OS Version: OS X 10.12.6 Flash Version: The initiator column is a really nice idea, it shows what caused the request. However the problem is it can be useless most the time because it can either go into minified code, or library code, such as requireJS or jQuery. https://gist.github.com/dustinboston/3288778 shows that its possible to generate a dependancy tree from require. By matching the url with the require object, you could then see which module pulled it in, then add that module to the initiator tab. {i know this is a long shot, but worth asking)
,
Nov 2 2017
Or if that’s too difficult, maybe an option to mark these scripts as a blackbox, so that the initiator is the next script in the stack. Developer tools already has the black boxed list, so you could hook into that
,
Nov 2 2017
As per comment#0 considering this issue as Feature and adding appropriate labels for further triaging. Thanks!
,
Nov 2 2017
,
Dec 13 2017
,
Dec 13 2017
I believe that blackboxing should help here. We can show top non blackboxed frame, the same way as we do for console messages.
,
Dec 13 2017
,
Dec 18 2017
@kozy sounds good to me!
,
Jan 3 2018
I merge this one into issue related to blackboxing support in network panel since now they have similar root. Thanks for your report. |
||||||
►
Sign in to add a comment |
||||||
Comment 1 by manoranj...@chromium.org
, Nov 1 2017