On the Slack Engineering Blog, Felix Rieseberg writes:
In practice, switching the analysis and the compiler on without changing code means that TypeScript will immediately attempt to understand your code. It uses built-in types and type definitions available for third party dependencies to analyze the code’s flow, pointing out subtle errors that went previously unnoticed. Wherever TypeScript cannot understand your code, it will assume a special type called “any” and simply move on.
Read more from the source: Several People Are Coding
Angular 2 reaches beta, packing a lot of changes from the preview
Angular 2 is truly a different framework from Angular 1. Although there is ngUpgrade and ngForward to help transition, the syntax and API are vastly different.
Angular 2 introduces a DOM parser that process html attributes before hitting the DOM. That means the new star, brackets and parentheses are easier to handle under the covers. And Angular 2 makes directives camelCase instead of kebab-case. You may also notice that directive attributes don’t show up on the DOM. All that is parsed out before rendering.
ng-if is now *ngIf and ng-repeat=”item in items” is now *ngFor=”#item of items”. ng-eventname directives are gone in favor of (eventname) syntax.
Property-based directives such as ng-class, ng-style, and ng-disabled are gone in favor of bracket-notated binding: [class.classname], [style.property], [disabled].
ng-model becomes [ngModel] for one-way binding and [(ngModel)] for two-way binding.
The digest cycle is gone, replaced by an immutabile object style checking.
Typescript (or the ES6 subset of Typescript) is recommended, but Angular 2 comes with a webpack-style server and live reloader for development.
Read the announcement on the blog: angularjs.blogspot.com or checkout the updated angular.io website.