refactor(core): move facades out of core
This is part of ongoing work to make core platform-independent. BREAKING CHANGE All private exports from 'angular2/src/core/facade/{lang,collection,exception_handler}' should be replaced with 'angular2/src/facade/{lang,collection,exception_handler}'.
This commit is contained in:
@ -14,7 +14,7 @@ import {
|
||||
Output
|
||||
} from 'angular2/core';
|
||||
|
||||
import {ListWrapper} from 'angular2/src/core/facade/collection';
|
||||
import {ListWrapper} from 'angular2/src/facade/collection';
|
||||
|
||||
/**
|
||||
* You can find the Angular 1 implementation of this example here:
|
||||
@ -35,7 +35,7 @@ class Order {
|
||||
private _dataService: DataService) {}
|
||||
|
||||
get items(): OrderItem[] { return this._dataService.itemsFor(this); }
|
||||
get total(): number { return this.items.map(i => i.total).reduce((a, b) => a + b); }
|
||||
get total(): number { return this.items.map(i => i.total).reduce((a, b) => a + b, 0); }
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user