-
Notifications
You must be signed in to change notification settings - Fork 130
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
@ng-idle/core document is not defined when using Angular Universal and Webpack Server #115
Comments
Try excluding the @ng-idle code when on the server. See following link angular/universal#860 (comment) |
grbsk
added a commit
that referenced
this issue
Jul 24, 2019
ssr option instructs interrupt sources to ignore targets derived from global context such as window or document so they can be safely used in ssr/universal apps. If you are using ssr/universal, do not use DEFAULT_INTERRUPTSOURCES. Instead, use `createDefaultInterruptSources({ssr: !isPlatformBrowser(platformId) })`. See docs or https://stackoverflow.com/a/46893433/64750 for information on how to use isPlatformBrowser. Fixes #77, #115
3 tasks
Had this problem when i include NgIdleKeepaliveModule in app.module. Any solution? dist...\server\main.js:1035 |
3 tasks
3 tasks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
My project is Angular 6.
I am trying to use Angular Universal:
https://github.com/angular/angular-cli/wiki/stories-universal-rendering
I have done all the setup. At the end when i run node dist/server.js, i get into following issue.
The issue here is @ng-idle/core which is being used inside my auth service.
As part of the angular universal setup, i have provided externals (which is missing from the code on the github for angular universal).
So here is my current webpack.server.config.js file
and the app.module
and the auth service has the following two imports.
How can i fix this issue?
The text was updated successfully, but these errors were encountered: