mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-09 11:13:57 +08:00
Update angular2 to alpha32
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
/// <reference path="angular2.d.ts"/>
|
||||
/// <reference path="router.d.ts"/>
|
||||
|
||||
// Use Typescript 1.4 style imports
|
||||
import ng = require("angular2/angular2");
|
||||
import {Component, View, Directive, bootstrap, bind, NgFor, NgIf} from "angular2/angular2";
|
||||
|
||||
class Service {
|
||||
|
||||
@@ -15,15 +14,15 @@ class Cmp {
|
||||
static annotations: any[];
|
||||
}
|
||||
Cmp.annotations = [
|
||||
ng.Component({
|
||||
Component({
|
||||
selector: 'cmp',
|
||||
injectables: [Service, ng.bind(Service2).toValue(null)]
|
||||
injectables: [Service, bind(Service2).toValue(null)]
|
||||
}),
|
||||
ng.View({
|
||||
View({
|
||||
template: '{{greeting}} world!',
|
||||
directives: [ng.NgFor, ng.NgIf]
|
||||
directives: [NgFor, NgIf]
|
||||
}),
|
||||
ng.Directive({
|
||||
Directive({
|
||||
selector: '[tooltip]',
|
||||
properties: [
|
||||
'text: tooltip'
|
||||
@@ -35,4 +34,10 @@ Cmp.annotations = [
|
||||
})
|
||||
];
|
||||
|
||||
ng.bootstrap(Cmp);
|
||||
@Component({selector: 'cmp2'})
|
||||
@View({templateUrl: '/index.html'})
|
||||
class Cmp2 {
|
||||
|
||||
}
|
||||
|
||||
bootstrap(Cmp);
|
||||
|
||||
Reference in New Issue
Block a user