vite-svg-loader icon indicating copy to clipboard operation
vite-svg-loader copied to clipboard

Component won't show: `Component is missing template or render function`

Open ThaDaVos opened this issue 1 year ago • 2 comments

I am using https://github.com/antfu/unplugin-vue-components to automatically load all my components, including the SVG ones - but when I use it - it won't show and my console shows the following warning: Component is missing template or render function

ThaDaVos avatar Aug 19 '22 11:08 ThaDaVos

Hi, did you load viteSvgLoader() in your vite.config.js file? If yes, then I think unplugin-vue-components doesn't pipe components through the loaded vite plugins. Maybe it's best then to contact them about this.

jpkleemans avatar Aug 31 '22 10:08 jpkleemans

It does work with other loaders, like the markdown one - and this other one works: https://github.com/antfu/unplugin-vue-components/issues/9

Also, I am not even loading it through that plugin and it doesn't work: image

Logo in question: image

ThaDaVos avatar Sep 01 '22 07:09 ThaDaVos