AfterContentChecked
视图完全初始化后触发。
(仅适用于组件)
import { Component, AfterContentChecked } from '@angular/core';
@Component({
selector: 'so-aftercontentchecked-component',
templateUrl: 'aftercontentchecked-component.html',
styleUrls: ['aftercontentchecked-component.']
})
class AfterContentCheckedComponent implements AfterContentChecked {
ngAfterContentChecked(): void {
console.log('Component content have been checked!');
}
}