angular-hybrid
angular-hybrid copied to clipboard
No provider for Injector!
Following the instructions to setup a hybrid angular router between AngularJS 1.7.3 and Angular app, I'm getting this error:
`Unhandled Promise rejection: StaticInjectorError(AppModule)[UpgradeModule -> Injector]:
StaticInjectorError(Platform: core)[UpgradeModule -> Injector]:
NullInjectorError: No provider for Injector! ; Zone: <root> ; Task: Promise.then ; Value: Error:
StaticInjectorError(AppModule)[UpgradeModule -> Injector]:
StaticInjectorError(Platform: core)[UpgradeModule -> Injector]:
NullInjectorError: No provider for Injector!`
StaticInjectorError(Platform: core)[UIView -> UIRouter]:
NullInjectorError: No provider for UIRouter!
at NullInjector.push.../../node_modules/@angular/core/fesm5/core.js.NullInjector.get (core.js:8894)
at resolveToken (core.js:9139)
at tryResolveToken (core.js:9083)
at StaticInjector.push.../../node_modules/@angular/core/fesm5/core.js.StaticInjector.get (core.js:8980)
at resolveToken (core.js:9139)
at tryResolveToken (core.js:9083)
at StaticInjector.push.../../node_modules/@angular/core/fesm5/core.js.StaticInjector.get (core.js:8980)
at resolveNgModuleDep (core.js:21120)
at NgModuleRef_.push.../../node_modules/@angular/core/fesm5/core.js.NgModuleRef_.get (core.js:21809)
at resolveDep (core.js:22180)```
@kushwahashiv Hi Did you find any solution for this? I have been stuck in the same issue for 2 days. Thanks
@subramanya4shenoy you can look at a hybrid example I built https://github.com/kushwahashiv/ng-hybrid
any update pls
Hey! I was not able to fix this. But we cam o now that one of our dependency (3rd party) had a circular deepndency. So we did a work arround by using the the 3rd party dependency locally and fixing the issue.
Generally, this is caused by circular dependency. Just try to segregate the component which is causing it and then take action.
All the best
On Wed, 11 Mar 2020, 12:00 pm Raghavendra M, [email protected] wrote:
any update pls
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/ui-router/angular-hybrid/issues/189?email_source=notifications&email_token=ABIHC5JDL2CG53BPX7VJRTDRG4VYNA5CNFSM4FRHOY5KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEOOJYYQ#issuecomment-597466210, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABIHC5IXMT6OLNFO4LZBVSTRG4VYNANCNFSM4FRHOY5A .
"No provider for UIRouter" might be not loading before bootstrapping
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. This does not mean that the issue is invalid. Valid issues may be reopened. Thank you for your contributions.