New issue
Advanced search Search tips

Issue 856322 link

Starred by 1 user

Issue metadata

Status: Duplicate
Merged: issue 534874
Owner:
Closed: Sep 25
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

Make it easier to flip between source-map code and actual code being executed

Reported by jus...@justingrant.net, Jun 25 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36

Steps to reproduce the problem:
1. Open any website that uses Babel (or another transpiler) and source maps. 
2. Open a pre-transpiled source file 
3. Set a breakpoint on a line in that file. 
4. Run the app, hit the breakpoint. Now, imagine that you need to debug further and want to see the actual (post-transpilation) JS code being executed. I know you can disable source maps, but that requires restarting the debugging session which can take a long time for intricate debugging states.  Also, variable names are sometimes different in post-transpiled code, which makes debugging harder unless you're actually looking at the post-transpilation code. 

What is the expected behavior?
There should be an easy way to navigate from the pre-transpilation code to the post-transpilation code, and vice versa. 

What went wrong?
The only way I could figure out during a debug session to find the post-transpilation code corresponding to a particular line of pre-transpilation code is to open bundle.js in the sources pane and then Cmd+F to find a snippet of code that's not changed by transpilation. Given that transpilation can change lots of things in the code, this trial-and-error grepping is time consuming.

These days, many (most?) sophisticated web apps use transpilation. Chrome should make it easier to debug them!

Did this work before? No 

Chrome version: 67.0.3396.87  Channel: n/a
OS Version: OS X 10.13.5
Flash Version:
 
Labels: Needs-Triage-M67
Labels: Triaged-ET TE-NeedsTriageHelp
As per comment #0, testing the issue require a javascript compiler e.g babel which seems to be out of TE-scope. Hence, adding label TE-NeedsTriageHelp for further investigation from dev team.

Thanks...!!
Owner: kozy@chromium.org
Status: Assigned (was: Unconfirmed)
Mergedinto: 534874
Status: Duplicate (was: Assigned)

Sign in to add a comment