Fix detect Nuxt3 defineNuxtComponent by sugitata · Pull Request #2311 · vuejs/eslint-plugin-vue (original) (raw)
- fixes vue/no-unused-properties does not work with defineNuxtComponent() #2191
- fixes vue/order-in-components is not working with defineNuxtComponent() #2057
Description
It's just a workaround like solution.
Add the defineNuxtComponent
alias for Nuxt3 projects, similar to #1088.
About defineNuxtComponent
The difference between defineNuxtComponent
and defineComponent
is only asyncData
and head
options are added on defineNuxtComponent
.
These options are not essential to check in vue-eslint-plugin, so it should be fine to treat it as defineComponent
.