Is it possible to warn or raise error when any function which makes use of getCurrentInstance
is used after awaited expression in async setup()
?
#3610
mukundshah
started this conversation in
General
Replies: 1 comment 2 replies
-
I think this is out-of-scope; eslint-plugin-vue should create a rule for it. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I got assigned on an old project, at my workplace. It was migrated to Nuxt 6 months ago.
Every vue file is using,
This shouldn't have worked at all. But it was working until the day I updated all the packages and the lock file. This shouldn't have worked in the first place, unless there was some package inside the lockfile that particularly allowed this.
The version of vue, vue sfc compiler and nuxt were, before I did the update
vue:
3.3.4
@vue/compiler-sfc:
3.3.4
nuxt:
3.6.0
At these version, they shouldn't have worked, or am I missing something?
Beside this, is it possible to cover/prevent situations like this through volar, or maybe eslint?
Beta Was this translation helpful? Give feedback.
All reactions