Closed omkar-kanekar1-tfs closed 4 months ago
Details on code
<router-view v-slot="{ Component }"> <component :is="Component" class="container" ref="componentRef" /> </router-view>
This is my router code.
Getting below error: [plugin:vite:vue] v-slot can only be used on components or tags.
Tried to rewrite syntax:
<router-view> <template v-slot="{ Component }"> <component :is="Component" class="container" ref="componentRef" /> </template> </router-view>
Getting different error: Codegen node is missing for element/if/for node. Apply appropriate transforms first.
As per error, if v-slot is not allowed on , there should be alternate approach which should work without errors.
Getting error: [plugin:vite:vue] v-slot can only be used on components or tags.
No response
This doesn’t seem to come from the router but from the vite plugin. BTW follow the issue guidelines next times please
Reproduction
Details on code
Steps to reproduce the bug
This is my router code.
Getting below error: [plugin:vite:vue] v-slot can only be used on components or tags.
Tried to rewrite syntax:
Getting different error: Codegen node is missing for element/if/for node. Apply appropriate transforms first.
Expected behavior
As per error, if v-slot is not allowed on, there should be alternate approach which should work without errors.
Actual behavior
Getting error: [plugin:vite:vue] v-slot can only be used on components or tags.
Additional information
No response