News

TypeScript Gets Faster, Adds Language Support with Update

The latest version fixes a compiler slowdown caused by the last version.

TypeScript continues to inch closer to a 1.0 version with the release of 0.9.1. The announcement was made by Microsoft's Jonathan Turner on the TypeScript blog.

The upgrade likely to matter most to developers is a speed boost. The last iteration of TypeScript, 0.9.0, included a rewritten compiler and language service. The downside of those improvements was a significant slowdown in the command-line compiler. It was "noticeably slower than in 0.8.3",  Turner wrote. The 0.9.1 release cures that issue, "improving both interactive and compiler performance," he said. In addition, developers working in Windows 8 and 8.1 and using the Visual Studio plugin will see even better speed, since Microsoft is using the latest version of the JavaScript engine Chakra.

Some language features have been added or improved as well, including:

  • New support for the 'typeof' operator in type positions. It provides a way to refer to the type of an expression.
  • Fewer restrictions on using 'this'. It allows classes to contain both methods on the prototype, and callback functions on the instance. "This lets you mix-n-match between 'closure' style and 'prototype' style class member patterns easily," Turner said.
  • A new compiler flag, '--noImplicitAny', has been added. The flag sends a warning when the compiler implicitly infers 'any,' when not explicitly stated in the code. It was an experimental feature in previous TypeScript versions, and became official with 0.9.1.
  • Support for using TypeScript within ASP.NET applications has been improved, although the blog didn't say exactly how. Instead, it implied that more information on that integration would be forthcoming.

The last previous update of TypeScript was 0.9, which was released in June. Visual Studio Magazine columnist Peter Vogel wrote an in-depth look at the changes in 0.9 last month. The biggest one was the addition of generics.

About the Author

Keith Ward is the editor in chief of Virtualization & Cloud Review. Follow him on Twitter @VirtReviewKeith.

comments powered by Disqus

Featured

  • New 'Visual Studio Hub' 1-Stop-Shop for GitHub Copilot Resources, More

    Unsurprisingly, GitHub Copilot resources are front-and-center in Microsoft's new Visual Studio Hub, a one-stop-shop for all things concerning your favorite IDE.

  • Mastering Blazor Authentication and Authorization

    At the Visual Studio Live! @ Microsoft HQ developer conference set for August, Rockford Lhotka will explain the ins and outs of authentication across Blazor Server, WebAssembly, and .NET MAUI Hybrid apps, and show how to use identity and claims to customize application behavior through fine-grained authorization.

  • Linear Support Vector Regression from Scratch Using C# with Evolutionary Training

    Dr. James McCaffrey from Microsoft Research presents a complete end-to-end demonstration of the linear support vector regression (linear SVR) technique, where the goal is to predict a single numeric value. A linear SVR model uses an unusual error/loss function and cannot be trained using standard simple techniques, and so evolutionary optimization training is used.

  • Low-Code Report Says AI Will Enhance, Not Replace DIY Dev Tools

    Along with replacing software developers and possibly killing humanity, advanced AI is seen by many as a death knell for the do-it-yourself, low-code/no-code tooling industry, but a new report belies that notion.

  • Vibe Coding with Latest Visual Studio Preview

    Microsoft's latest Visual Studio preview facilitates "vibe coding," where developers mainly use GitHub Copilot AI to do all the programming in accordance with spoken or typed instructions.

Subscribe on YouTube