Angular Partners With TypeScript
Written by Alex Armstrong   
Tuesday, 10 March 2015

Google's Angular team revealed at ng-conf that it has been working closely with Microsoft's TypeScript team to bring new features to Angular 2.0.

angularbanner

Google's AngularJS is one of the most popular UI frameworks and hence in use in many projects. When Angular 2.0 was announced last Fall (see AngularJS 2.0 Is Radically Different) its develop community was dismayed to discover that it would not be backward compatible and so would leave existing projects using AngularJS 1.3 dead in the water. 

At that time its team issued a blog post that tried to soften the blow and also provide a glimmer of hope saying:

"Our goal with Angular 2 is to make the best possible set of tools for building web apps not constrained by maintaining backwards compatibility with existing APIs. Once we have an initial version of Angular 2, we'll start to work on a migration path for Angular 1 apps."

Back in 2014 it was stated that  Angular 2 will introduce AtScript, an extension of the TypeScript optional typing. Now it transpires that Angular 2 is being built with Typescript.

On the Typescript blog, Jonathan Turner explains how this will enhance Anglular 2:

We have worked with the Angular team to design a set of new features that will help you develop cleaner code when working with dynamic libraries like Angular 2, including a new way to annotate class declarations with metadata.  Library and application developers can use these metadata annotations to cleanly separate code from information about the code, such as configuration information or conditional compilation checks.  

We've also added a way to retrieve type information at runtime.  When enabled, this will enable developers to do a simple type introspection.  To verify code correctness with additional runtime checks.  It also enables libraries like Angular to use type information to set up dependency injection based on the types themselves.

A demo created for ng-conf as a preview of Angluar 2 is a TODOMVC example that can be tried out on GitHub. Here it shows TypeScript autocomplete in Sublime 3:  

 Ang2TypeScript

 

Although it may seem strange to find Microsoft and Google in such close co-operation, perhaps it exemplifies the commitment of both to open source. On his blog Micrcrosoft's S.Somesegar writes:

I’m proud of the productive relationship and partnership we’ve built between the TypeScript and Angular teams. Both teams are looking forward to continuing to move TypeScript and JavaScript forward together in the future, including working with the ECMAScript standards body on the future of types in JavaScript.

Of course being used on a big project like Angular 2 makes TypeScript seem all the more like a real language.

angularicon

Banner


The Advent of SQL 2024 Has Commenced
11/12/2024

It's Advent - the time of year when we countdown the days to Christmas - and if your are a programmer complete daily coding challenges with the Advent of Code, the Advent of Perl, the Advent of Java,  [ ... ]



The Art Of Computer Programming - A Great Present
15/12/2024

If you are looking for a programmer present this holiday season, there is one book, or set of books, that should be top of any list... Donald Knuth's The Art of Computer Programming.


More News

 

espbook

 

Comments




or email your comment to: comments@i-programmer.info

Last Updated ( Thursday, 26 March 2015 )