2019年3月21日
摘要: https://stackoverflow.com/questions/41364386/whats-the-difference-between-markforcheck-and-detectchanges 阅读全文
posted @ 2019-03-21 17:49 chen8840 阅读(370) 评论(0) 推荐(0) 编辑
摘要: 1.ngOnChanges只有在输入值改变的时候才会触发,如果输入值(@Input)是一个对象,改变对象内的属性的话是不会触发ngOnChanges的。 2.组件的变化检测: 2a.changeDetection如果是ChangeDetectionStrategy.Default的话,无论输入值(@ 阅读全文
posted @ 2019-03-21 15:32 chen8840 阅读(5482) 评论(0) 推荐(0) 编辑