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
getCurrentInstance type not correct #12596
Comments
I guess you are not supposed to access the component internals :) |
In vue3:
in @vue/composition-api
They both returned
|
They are on |
Yes, i can do this by myself. But it cannot be smoothly upgrade from @vue/composition-api. Is there any plan to add support for those api ?(This seems to be easy to implement) |
same issue :( |
|
we need to use .proxy to access to the public properties and not the internal properties vuejs/vue#12596 (comment)
@yyx990803 considering that this API is not public, how do you suggest to get the vue app instance (the one created with createApp() ) from any Vue component (created using <script setup>) ? Currently I was using |
@yyx990803 I know it's a closed issue and I understand your point of view, and I actually agree with you, but I think it's a good think to leave |
Does anyone know an alternative approach to get the access to the Vue instance (for v2.7)? |
Vue instance can be accessed by |
Version
2.7.0
Steps to reproduce
vue2.7 getCurrentInstance type was not match vue3 & @vue/composition-api
see:
What is expected?
has correct type
What is actually happening?
not match
The text was updated successfully, but these errors were encountered: