fix(benchmarks): fix scrolling benchmark; add more tests

This commit is contained in:
Yegor Jbanov
2015-02-13 17:30:56 -08:00
parent 6197ab0e48
commit 6d45153b67
3 changed files with 51 additions and 4 deletions

View File

@ -4,8 +4,9 @@ import {MapWrapper} from 'angular2/src/facade/collection';
import {Parser, Lexer, ChangeDetector, ChangeDetection}
from 'angular2/change_detection';
import {bootstrap, Component, Viewport, Template, ViewContainer, Compiler}
from 'angular2/angular2';
import {
bootstrap, Component, Viewport, Template, ViewContainer, Compiler, onChange
} from 'angular2/angular2';
import {reflector} from 'angular2/src/reflection/reflection';
import {CompilerCache} from 'angular2/src/core/compiler/compiler';
import {DirectiveMetadataReader} from 'angular2/src/core/compiler/directive_metadata_reader';
@ -166,6 +167,7 @@ export function setupReflectorForAngular() {
'parameters': [[ViewContainer]],
'annotations' : [new Viewport({
selector: '[foreach]',
lifecycle: [onChange],
bind: {
'in': 'iterable[]'
}

View File

@ -65,7 +65,7 @@ export function setupReflectorForScrollItem() {
FormattedCellComponent
],
inline: `
<div [style]="itemStyle">
<div class="row" [style]="itemStyle">
<company-name [company]="offering.company"
[cell-width]="companyNameWidth">
</company-name>