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

Current instance is not unset after rendering error on SSR #6110

Closed
danielroe opened this issue Jun 14, 2022 · 1 comment · Fixed by #6184
Closed

Current instance is not unset after rendering error on SSR #6110

danielroe opened this issue Jun 14, 2022 · 1 comment · Fixed by #6184
Labels
🐞 bug Something isn't working scope: ssr

Comments

@danielroe
Copy link
Member

Vue version

3.2.37

Link to minimal reproduction

https://stackblitz.com/edit/github-qw7apw

Steps to reproduce

Click 'Trigger error'. It will try to load a component where there is a JS error.

Then click 'click here to see stale instance' - it will perform a hard reload, calling getCurrentInstance() on the server and revealing that the instance was not unset.

What is expected?

I expect the current component instance to be unset if there is a rendering error.

What is actually happening?

When there is a vue rendering error, the current component instance is not unset.

System Info

No response

Any additional comments?

In Nuxt we were relying on getCurrentInstance to return null if called outside of a Vue lifecycle. See nuxt/nuxt#14112.

@misaon
Copy link

misaon commented Sep 6, 2022

+1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🐞 bug Something isn't working scope: ssr
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants