角分量不是已知元素
最近,当我尝试运行服务命令时,我将Angular项目从Angular 8升级到Angular 9。
error NG8001: 'app-abcd-breadcrumb' is not a known element:
1. If 'app-abcd-breadcrumb' is an Angular component, then verify that it is part of this module.
2. If 'app-abcd-breadcrumb' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
error NG8001: 'router-outlet' is not a known element:
1. If 'router-outlet' is an Angular component, then verify that it is part of this module.
2. If 'router-outlet' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
5 <router-outlet></router-outlet>
有人可以帮我吗?这些组件是我为项目创建的组件。它不是任何库组件
I have recently upgraded my angular project from angular 8 to angular 9, when I try to run serve command I am getting below error.
error NG8001: 'app-abcd-breadcrumb' is not a known element:
1. If 'app-abcd-breadcrumb' is an Angular component, then verify that it is part of this module.
2. If 'app-abcd-breadcrumb' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
error NG8001: 'router-outlet' is not a known element:
1. If 'router-outlet' is an Angular component, then verify that it is part of this module.
2. If 'router-outlet' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
5 <router-outlet></router-outlet>
Can anyone please help me on this ? these components are the components created by me for the project. it is not any library component
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您需要在模块内声明组件。
You need to declare the component inside the module.