Steps to reproduce
-Open this web page in IE 11: https://ie11sourcemaps.azurewebsites.net/ex2.html
-Open the F12 tools and open the Debugger tab.
-Click the “Load the sources mapped to this generated file” if this is not enabled.
-Click the folder button and select Class1.ts.
-Set a breakpoint on line 9 by either clicking the mouse on it and pressing F9 or clicking the gray area to the left of line 9. You will see in the Breakpoints area that the breakpoint was set at "Class1.ts (2,18)", which is incorrect. (Expected "Class1.ts (9,13)" or "Class1.ts (9,17)").
-Refresh the page. When the breakpoint is hit, evaluating namePart or numberPart return undefined. (Expected: namePart = "Class", numberPart = undefined). Press play to exit the debugger.
-Clear all breakpoints.
-Scroll about half-way over and right-click where it says "numberPart=1;". Choose "Insert Breakpoint". (Note there is also an annoying display bug here where right-clicking makes the code window snap left, though the breakpoint will still be set properly if you click “Insert Breakpoint” on the context menu that appears).
-Click the “Load the sources mapped to this generated file” button.
-Now you should see that the breakpoint is set in the correct location "Class1.ts (9,17)" (though the minifier eliminated the redundant var statement, so it is four characters over). The breakpoint should work correctly. Refreshing the page should hit the breakpoint on line 9 and evaluating namePart should return “Class” but numberPart should still be undefined.
The breakpoint should display as either "Class1.ts (9,13)" or "Class1.ts (9,17)". When the page is refreshed, the breakpoint should get hit during the execution of the function. Testing namePart by hovering over it with the pointer or by evaluating it on the console should return "Class". Testing numberPart by hovering over it with the pointer or by evaluating it on the console should return undefined.
Dev Channel specific:
Comments and activity
- Microsoft Edge Team
Changed Assigned To to “Mara P.”
Changed Assigned To to “Dan M.”
Changed Assigned To from “Dan M.” to “Rob L.”
Changed Assigned To from “Rob L.” to “IE S.”
Changed Status to “Won’t fix”
Thank you for providing this information about the issue. Source maps rarely give great results on minified code. Currently, we do not plan to release a fix for this problem. We are considering a solution for a future build.
The MS Edge Team