angular-activatedroute

Angular error: no provider for ActivatedRoute

▼魔方 西西 提交于 2019-11-30 14:30:59
问题 i m using angular 5 latest and i am hitting below exception ERROR Error: StaticInjectorError(AppModule)[AppComponent -> ActivatedRoute]: StaticInjectorError(Platform: core)[AppComponent -> ActivatedRoute]: NullInjectorError: No provider for ActivatedRoute! at _NullInjector.get (core.js:1002) at resolveToken (core.js:1300) at tryResolveToken (core.js:1242) at StaticInjector.get (core.js:1110) at resolveToken (core.js:1300) at tryResolveToken (core.js:1242) at StaticInjector.get (core.js:1110)