jpkleemans / vite-svg-loader

Vite plugin to load SVG files as Vue components
MIT License
557 stars 59 forks source link

Vue 2 support #10

Closed ajerez closed 3 years ago

ajerez commented 3 years ago

Any plans to support vue 2?

I have this error in a vite project with vue 2:

Uncaught SyntaxError: The requested module '/node_modules/.vite/vue.js' does not provide an export named 'Fragment

Thanks

jpkleemans commented 3 years ago

Hi, Vite doesn't support Vue 2 at the moment. See https://github.com/vitejs/vite/issues/305

rightaway commented 3 years ago

@jpkleemans With vite-plugin-vue2 vite can be used with Vue 2. Would you consider adding support for Vue 2? Will be a while before Vue 3 becomes used by everyone.

rogatty commented 2 years ago

See https://github.com/pakholeung37/vite-plugin-vue2-svg for an alternative.

jaw52 commented 1 year ago

Both vue2 and vue3 are supported https://www.npmjs.com/package/unplugin-svg-vue-component