Closed wezzle closed 11 months ago
Setting the pragma to h and the jsxRuntime to classic-preact allows this plugin to be used for preact projects.
h
classic-preact
Example config:
import preact from '@preact/preset-vite' import svg from 'vite-plugin-react-svg' // https://vitejs.dev/config/ export default defineConfig({ plugins: [ preact(), svg({ defaultExport: 'component', pragma: 'h', jsxRuntime: 'classic-preact', }), ], })
Setting the pragma to
h
and the jsxRuntime toclassic-preact
allows this plugin to be used for preact projects.Example config: