Closed
Description
After updating to 10.4.0 we saw a bunch of tests that were suddenly failing. After a bit of digging I realized each component implemented OnChanges
and in the ngOnChanges()
function we were looking for an @Input
property to be in the changes object. It seems with the latest changes any @Input
property that is set in componentProperties
is never in the changes object in ngOnChanges
.
Quick example:
@Component
class Component implements OnChanges {
@Input() someProperty: string
ngOnChanges(changes: SimpleChanges) {
if(changes.someProperty) {
// Do something if @Input property changed
}
}
}
render(Component, {
componentProperties: {someProperty: 'value'}
})