diff --git a/examples/vue3-vite/vite.config.ts b/examples/vue3-vite/vite.config.ts index c581983..fa17817 100644 --- a/examples/vue3-vite/vite.config.ts +++ b/examples/vue3-vite/vite.config.ts @@ -23,6 +23,7 @@ export default defineConfig({ return nameArr.join('-').replace(/\.svg$/, '') }, optimizeOptions: undefined, + vueVersion: 3, }), ], }) diff --git a/src/core/index.ts b/src/core/index.ts index acb898f..b58dcd2 100644 --- a/src/core/index.ts +++ b/src/core/index.ts @@ -34,7 +34,7 @@ const unplugin = createUnplugin(options => ({ }, vite: { async load(_, ssr) { - if (ssr) + if (ssr?.ssr) return null return { code: moduleCode,