SSR
dunice-boldirev opened this issue · comments
Hello!
I trying integrate server side rendering in my project.
When I add vue2-simplert
import Simplert from 'vue2-simplert'
I get error
ReferenceError: document is not defined
Does have way for use vue2-simplert with server side rendering?
Thank you
Actually, I am not familiar with SSR.
But when I look the code from vue2-simplert
not found any window
or document
usage like your error log.
Oh ya, got it.
This is because I packed JS with CSS inside one file.
Need to refactor webpack build config to extract CSS from the file.
But this thing will break another previous version.
So, will look for another workaround.
Hope can fixed soon.
@mazipan Thanks for the quick response. I'll wait for updates. Thank you again!
Check wiki
here : https://github.com/mazipan/vue2-simplert/wiki/Usage-Guidance#ssr-import-simplert-from-node_modules-for-ssr
Let me know and open another issue if something wrong