Add Angular2Spa template

This commit is contained in:
SteveSandersonMS
2016-02-23 23:13:20 +00:00
parent a55394638f
commit de488987c1
39 changed files with 1234 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
<h2>Counter</h2>
<p>This is a simple example of an Angular 2 component.</p>
<p>Current count: <strong>{{ currentCount }}</strong></p>
<button (click)="incrementCounter()">Increment</button>

View File

@@ -0,0 +1,15 @@
import * as ng from 'angular2/core';
@ng.Component({
selector: 'counter'
})
@ng.View({
template: require('./counter.html')
})
export class Counter {
public currentCount = 0;
public incrementCounter() {
this.currentCount++;
}
}