refactor(benchmarks): make setup nicer

- simplify and correct systemjs config
- remove deep imports into Ng2 packages to work with bundles
- have separate Ng2 and Polymer bootstrap files
This commit is contained in:
Tobias Bosch
2016-08-30 14:17:37 -07:00
parent f7b5478e9f
commit 6ea5b05e7c
25 changed files with 260 additions and 320 deletions

View File

@ -20,10 +20,10 @@
</p>
<div>
<binary-tree id="app"></binary-tree>
<binary-tree id="root"></binary-tree>
</div>
<script src="../../bootstrap.js"></script>
<script src="../../bootstrap_polymer.js"></script>
</body>
</html>

View File

@ -1,14 +1,13 @@
import {bindAction} from '@angular/platform-browser/testing/benchmark_util';
import {buildTree, emptyTree} from '../app/util';
import {bindAction} from '../../util';
import {buildTree, emptyTree} from '../util';
declare var Polymer: any;
export function main() {
const rootEl: any = document.querySelector('binary-tree');
rootEl.data = emptyTree();
rootEl.data = emptyTree;
function destroyDom() { rootEl.data = emptyTree(); }
function destroyDom() { rootEl.data = emptyTree; }
function createDom() { rootEl.data = buildTree(); }