2015-12-11 16:31:30 -05:00
|
|
|
import {Component, View} from 'angular2/core';
|
|
|
|
import {bootstrap} from 'angular2/platform/browser';
|
2015-06-16 13:46:12 -04:00
|
|
|
|
|
|
|
@Component({
|
|
|
|
selector: 'my-app'
|
|
|
|
})
|
|
|
|
@View({
|
|
|
|
template: '<h1>Hello {{ name }}</h1>'
|
|
|
|
})
|
|
|
|
// Component controller
|
|
|
|
class MyAppComponent {
|
|
|
|
name: string;
|
|
|
|
|
|
|
|
constructor() { this.name = 'Alice'; }
|
|
|
|
}
|
|
|
|
|
2015-10-01 22:49:45 -04:00
|
|
|
bootstrap(MyAppComponent);
|