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
TypeError: Cannot destructure property 'createComponentInstance' of 'r.ssrUtils' as it is null. #3379
Comments
You should use createSSRApp(Main()).mount(document.getElementById('app')) For that workaround, yes, that’s because the default behavior of webpack is that the |
@HcySunYang How does using I am trying to get SSR working in Vue 3 with Webpack, and running into the same error:
Any tips? 😬 |
Hello @reinink! In order to make it working at the server webpack config I needed to externalize dependencies: |
@carlosmaniero THANK YOU SO MUCH. That worked! 🙌 |
Version
3.0.7
Reproduction link
https://github.com/carlosmaniero/vue-create-component-instance-error
Steps to reproduce
More info:
There is also this webpack warning:
What is expected?
To have SSR working 😀
What is actually happening?
TypeError: Cannot destructure property 'createComponentInstance' of 'r.ssrUtils' as it is null.
If I remove this line from webpack server config:
https://github.com/carlosmaniero/vue-create-component-instance-error/blob/master/webpack.server.js#L14
I have the same error from server.
Also, I'm using the webpack configuration provided by
@vue/cli-service
. All I did was about to remove some stuff I didn't want to use.There is this workaround:
Extracted from: #2244 (comment)
However, it increases significantly the build time beyond that it also result in an empty hydration result.
The text was updated successfully, but these errors were encountered: