-
Notifications
You must be signed in to change notification settings - Fork 435
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
ApplicationRef.isStable is always false when using this package #961
Comments
Hey, thanks for the issue. Can you do a PR, then we can test it. Thanks. |
I have submitted the PR; I have adjusted the 'potential fix' a little bit to make it work nice with the already existing unit tests. Also this should be considered a performance enhancement since ChangeDetection will now also not be called after each interval and timeout. |
Hey @BillyBlaze , thanks for this. In the mentioned issue we now have to emit from |
Hi @FabianGosebrink, I do not work anymore at the company where I implemented the code, so it's hard for me to verify/test it. However there is one emit that is not run inside the zone: Hopefully this issue is fixed if we just change: into:
|
Hey @BillyBlaze , thanks for the quick reply. Yes, this would be my first approach as well. Thanks, I will try that! Thank you! |
Quick update. In my tests this fixes it. Thank you! |
Describe the bug
When you kick-off the setup (with checkAuth) then this package will create intervals and timeouts. When using Service workers it's important to get the application into stable mode or else the new version isn't downloaded. However this is not possible because this package is making it unstable and it will never turn stable.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
intervals and timeouts should be run outside the NgZone so that it wont interfere with the "stability" of Angular.
This package reaches stable for me when these two culprits are run outside angular:
angular-auth-oidc-client/projects/angular-auth-oidc-client/src/lib/callback/intervall.service.ts
Line 18 in 710af82
angular-auth-oidc-client/projects/angular-auth-oidc-client/src/lib/iframe/check-session.service.ts
Line 132 in 03aa2ad
Potential fixes
intervall.service.ts:
check-session.service.ts:
The text was updated successfully, but these errors were encountered: