Suppose I have simple Angular2 component
@Component({ selector: \'parent\' })
@View({
template: `
You can put your additional logic or calculations into onChange method, that is called after all of component's bound properties are updated.
@Component({
selector: 'child',
properties : ['model']
})
@View({
template: `
Child {{ model }}
`,
})
class Child {
model: number;
onChange(map){
if(map.model) {
console.log('doing crazy stuff here');
console.log(map.model); //SimpleChange {previousValue: 43, currentValue: 44}
}
}
}
Plunker