Angular-constructor和ngOnInit区别 参考文档:https://blog.csdn.net/u010730126/article/details/64486997 总结:constructor做依赖注入,避免业务操作; ngOninit做初始化