Announcing TypeScript 0.8.1

Announcing TypeScript 0.8.1

Rate This
  • Comments 21

Announcing TypeScript 0.8.1

We released the first public preview of TypeScript last month, and have been excited to see the great reaction from the developer community.  Since the preview, we’ve seen an influx of suggestions and bug reports, integration into various build and testing tools, and declare files for a variety of existing JavaScript libraries

Today, we’re happy to announce the second publically available preview of TypeScript: version 0.8.1.  This preview focuses on addressing critical bugs and adding one of the most requested features: source level debugging.

Debugging

TypeScript now supports source level debugging!  The source map format has been gaining popularity as a way of debugging languages which translate to JavaScript and is supported by a variety of browsers and tools.  With version 0.8.1, the TypeScript compiler officially supports source maps.  Additionally, the new version of TypeScript for Visual Studio 2012 supports debugging using the source map format.

From the command-line, we now fully support the use of the --sourcemap flag, which outputs a source map file corresponding to the JavaScript output.  This file will allow directly debugging the original TypeScript source in source map-enabled browsers and Visual Studio.

To enable debugging in Visual Studio select ‘Debug’ from the dropdown after creating an HTML Application with TypeScript project.

Once selected, you can set breakpoints and step directly in your TypeScript code.

  

You can also see your current location using the call stack.  

 

Bug Fixes

This release addresses many issues found in our first public preview.  These fixes have improved compiler stability, compiler correctness, and UTF-8 support.  A big “thank you!” to everyone who has helped so far by reporting bugs and participating in the issue tracker and forums.  

Breaking Changes

There are two known breaking changes since v0.8.0: 

  • Projects created from the Visual Studio templates using v0.8.0 will need to be manually updated to work with v0.8.1.  Going forward, this should not be necessary.  This post contains details of the MSBuild to use when converting projects. 
  • The compiler was previously incorrectly allowing non-exported interfaces in a module to be used from outside the module.  These must now be exported explicitly per the specification.

Conclusion

The version 0.8.1 preview is now available for Visual Studio, npm, and source.  We’re excited to see how people will continue using, building upon, and integrating TypeScript into their JavaScript development, and we’d love to get your feedback.

 

Leave a Comment
  • Please add 8 and 6 and type the answer here:
  • Post
  • Source maps support in VS? That's AWESOME!

    Does it work with any of the other source map generators (like Uglify2)?

  • The compiler will output the .map file.  For other tools in your toolchain, as long as they can read the source map file, they should work.

  • I was actually wondering about the VS tooling. If say I have a file that is just .js, I run a minifier that outputs a source map file (UglifyJS2 being one of them) will I be able to have the same debugging experience? Or is the source map debugging tied to TypeScript

  • Looking good.  Still no ExtJS support.

  • Good stuff! when are generics coming?!

  • Thanks! Source level debugging in VS was my #1 request for the new release!

    However can't get it to work - I'v added --sourcemap output and changed to the "Debug" configuration and now VS crashes every time I hit the "start debugging" button.

    ---bjorn

  • I haven't been used Visual Studio since 2008. Typescript intellisense changes the game. Source maps is icing on the cake. I even kicked coffeescript out of the door!

    Node.js debugging? That would be heaven.

  • ExtJS is basically a commercial product, why should MS support it? I still haven't forgotten ExtJS open source license switcharoo.

  • Congrats.

  • I also find that trying to debug with v0.8.1 causes VS to crash immediately on both updated 0.8.0 projects and new TypeScript projects.

  • I also see Visual Studio crash when I try to debug. Looking forward to using this functionality when it works! ;)

  • @Andrew @Dave @Bjorn (and anyone seeing the crash) - What version of VS are you using?  Also, did you happen to uninstall the previous version of the VS plugin before installing the new one?  

  • @Aaron Powell - the source map support may work for minified code as well, though we specifically are targeting debugging TypeScript in this release

  • I was on the fence about TS, having used CoffeeScript for some time and recognized a need for better web development tools. But source level debugging in Visual Studio, complete with refactoring support? Ok, I'm sold. Now I'm feelin' the love. I'll be switching my code over this weekend.

    Nice work!

  • @jntrnr I'm using VS 2012 Premium. I didn't at first, but then I removed both versions and re-installed and am still seeing this behavior.

Page 1 of 2 (21 items) 12