News

TypeScript 2.0 Nears Final Release

Microsoft doesn't expect to be adding any major new features to its upcoming open source TypeScript 2.0, which was recently made available in a Release Candidate version.

"TypeScript 2.0 is almost out, and today we're happy to show just how close we are with our release candidate!" said Daniel Rosenwasser in a blog post last week.

TypeScript, created in 2012, is a superset of the JavaScript programming language. It compiles to simple JavaScript while adding typing capabilities and object-oriented concepts such as classes.

"Types enable JavaScript developers to use highly productive development tools and practices like static checking and code refactoring when developing JavaScript applications," its site says.

"Types are optional, and type inference allows a few type annotations to make a big difference to the static verification of your code. Types let you define interfaces between software components and gain insights into the behavior of existing JavaScript libraries."

As explained on its GitHub site, version 2.0 includes many new features, such as null- and undefined-aware types, control flow based type analysis, tagged union types and many more. Some of the new functionality is being debuted in the new 2.0 RC.

"This RC gives an idea of what the full version of 2.0 will look like, and we're looking for broader feedback to stabilize and make 2.0 a solid release," Rosenwasser said. "Overall, the RC should be stable enough for general use, and we don't expect any major new features to be added past this point."

Rosenwasser goes on to discuss those aforementioned tagged unions; more literal types such as boolean, number and enum member; and many more features including globs, includes and excludes.

"TypeScript 2.0 finally adds support for globs," he said. "Globs allow us to write out wildcards for paths, making them as granular as you need without being tedious to write."

Developers interested in checking out TypeScript 2.0 can download it for Visual Studio 2015 (Update 3 required) or install it through the NuGet or npm package managers.

About the Author

David Ramel is an editor and writer for 1105 Media.

Featured

comments powered by Disqus
Upcoming Events

AppTrends

Sign up for our newsletter.

I agree to this site's Privacy Policy.