Skip to content
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

DefaultServerRenderer2.setProperty error in SSR angular universal #1144

Closed
alikarimii opened this issue Jan 10, 2019 · 0 comments · Fixed by #1164
Closed

DefaultServerRenderer2.setProperty error in SSR angular universal #1144

alikarimii opened this issue Jan 10, 2019 · 0 comments · Fixed by #1164
Assignees

Comments

@alikarimii
Copy link

I use universal-starter with some change in server.ts. I added domino to define window object to prevent some "window not define" error on the server side.

This is error log:
ERROR TypeError: Cannot read property 'toLowerCase' of undefined at EmulatedEncapsulationServerRenderer2.DefaultServerRenderer2.setProperty (/universal/dist/server.js:125246:34) at BaseAnimationRenderer.setProperty (/universal/dist/server.js:124312:27) at SafeSubscriber._next (/universal/dist/server.js:161724:28) at SafeSubscriber.__tryOrUnsub (/universal/dist/server.js:27968:16) at SafeSubscriber.next (/universal/dist/server.js:27906:22) at Subscriber._next (/universal/dist/server.js:27849:26) at Subscriber.next (/universal/dist/server.js:27826:18) at TakeWhileSubscriber.nextOrComplete (/universal/dist/server.js:37724:25) at TakeWhileSubscriber._next (/universal/dist/server.js:37719:14) at TakeWhileSubscriber.Subscriber.next (/universal/dist/server.js:27826:18)

the repo for test: angular-universal-nebular-theme
run npm run build:ssr && npm run serve:ssr and then go to route /sample that I used nebular theme

I asked this question in stackoverflow too.
some one comment on my question:

This code causes that error akveo/nebular/... We can't set property on document through renderer. It only applies elements. We can use this.document.dir = direction instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants