-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error Circular dependency when adding either HttpClient or HttpService to AuthenticationService #436
Comments
Have you tried with |
Hi @creal73, yes i already try both base on prev issue. Do i miss something? Coz i just generate new project and want to call my auth beckend. For now its work if i use old http. Thanks |
See my answer to the same issue #432 |
Thanks @sinedied, will try this night. |
@sinedied , @creal73 thanks for your help, here my solution in case someone needed, Create another service in my case
and then you can use that service inside here is my and be careful to use import from app/core or direct import service because it will make circular dependent. |
I'm submitting a...
[x] Bug report
[ ] Feature request
[ ] Documentation issue or request
Current behavior
Error Circular dependency when adding either HttpClient or HttpService to AuthenticationService
src\app\core\http\http.service.ts -> src\app\core\interceptors\error-handler.interceptor.ts -> src\app\core\index.ts -> src\app\core\core.module.ts -> src\app\core\http\http.service.ts
src\app\core\index.ts -> src\app\core\core.module.ts -> src\app\core\http\http.service.ts -> src\app\core\interceptors\error-handler.interceptor.ts -> src\app\core\index.ts
src\app\core\interceptors\error-handler.interceptor.ts -> src\app\core\index.ts -> src\app\core\core.module.ts -> src\app\core\http\http.service.ts -> src\app\core\interceptors\error-handler.interceptor.ts
Expected behavior
Success compile and can call from HttpClient or HttpService
Minimal reproduction of the problem with instructions
ngx new
Environment
Others:
Same issue with:
generator work fine if i use Deprecated Http and i can't use benefit of HttpService like cache.
Thank you for your great work at this generator.
The text was updated successfully, but these errors were encountered: