Reputation: 32758
I am using Typescript and I am compiling to javascript with inline sourcemaps. Here's an example of my javascript file:
var AccessHomeController = (function () {
function AccessHomeController($scope) {
this.$scope = $scope;
$scope.home = this;
}
AccessHomeController.$inject = [
'$scope'
];
return AccessHomeController;
})();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWNjZXNzL2NvbnRyb2xsZXJzL0hvbWVDb250cm9sbGVyLmpzIiwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXMiOlsiYWNjZXNzL2NvbnRyb2xsZXJzL0hvbWVDb250cm9sbGVyLmpzIl0sInNvdXJjZXNDb250ZW50IjpbInZhciBBY2Nlc3NIb21lQ29udHJvbGxlciA9IChmdW5jdGlvbiAoKSB7XG4gICAgZnVuY3Rpb24gQWNjZXNzSG9tZUNvbnRyb2xsZXIoJHNjb3BlKSB7XG4gICAgICAgIHRoaXMuJHNjb3BlID0gJHNjb3BlO1xuICAgICAgICAkc2NvcGUuaG9tZSA9IHRoaXM7XG4gICAgfVxuICAgIEFjY2Vzc0hvbWVDb250cm9sbGVyLiRpbmplY3QgPSBbXG4gICAgICAgICckc2NvcGUnXG4gICAgXTtcbiAgICByZXR1cm4gQWNjZXNzSG9tZUNvbnRyb2xsZXI7XG59KSgpO1xuIl0sInNvdXJjZVJvb3QiOiIvc291cmNlLyJ9
When I use the Chrome Developer tools and select "Enable Source Maps" and the look at the source files this is exactly what I see. All I see is the source of a javascript and the sourcemap details.
So how can I see the original .ts and how can the inline sourcemap help me ?
Upvotes: 0
Views: 1311
Reputation: 276199
When I use the Chrome Developer tools and select "Enable Source Maps" and the look at the source files this is exactly what I see.
Press CTRL+O in developer tools and type .ts
you should be able to see .ts
files.
Upvotes: 1