Typescript with sourcemaps

Typescript works perfectly. Except I can't get it to work with sourcemaps. The sourcemaps do get created (I did manually add the --sourcemap argument to tsc background task though), but it doesn't seem like my breakpoints get hit.

Can anyone get them to work? This would be soooooo wonderfull!

(Btw, just how GREAT is contextual help in webstorm? bringing up out of date extensions, showing how to setup typescript. I had the whole thing working in five minutes! THIS is the way to make software!).

M.

7 comments

Could you specify OS and WebStorm version?

0

The OS is Windows 7 and I am running WebStorm 6 EAP 126.37 (Jan. 24th).

M.

0

Could you attach test project or any test files? May be http://youtrack.jetbrains.com/issue/WEB-6402 (try to clear browser cache)?

0

Certainly. Here are the project files. I tried clearing the cache in chrome to no avail. I included a screenshot below of the elements that are in the resources. I notice the sourcemap files aren't in there. Should the .map files be in there?

It may be worth mentionning that I'm not serving files through a server but rather directly (ie: the link in chrome show this: file:///C:/Users/win7/WebstormProjects/TestV6/index.html). Could that be the source of the problem?
projectFiles.png

M.



Attachment(s):
TestV6.rar.zip
0

1) Firefox is not supported, please see http://youtrack.jetbrains.com/issue/WEB-2337 Only Google Chrome.
2) Debug sourcemap-backed bootstrap code is not supported, please see http://youtrack.jetbrains.com/issue/WEB-6413 You can debug event handlers or any other code, executing after page load.

0

I noticed that when loading the source directly from the file system, chrome will load static files via XHR only once, and serve the same contents on subsequent XHR requests to the same file. Not absolutely sure about the behavior for non-XHR load requests.

So you might be right that your problems with source maps are related to loading your document from the file system. Why you don't see what happens if you load it via a web server?

0

Please sign in to leave a comment.