$ npm install -D unplugin-solid
$ yarn add -D unplugin-solid
$ pnpm add -D unplugin-solid
Vite
// vite.config.ts
import Solid from "unplugin-solid/vite";
export default defineConfig({
plugins: [
Solid({
/* options */
}),
],
});
Rollup
// rollup.config.js
import Solid from "unplugin-solid/rollup";
export default {
plugins: [
Solid({
/* options */
}),
// other plugins
],
};
Webpack
// webpack.config.js
module.exports = {
/* ... */
plugins: [
require("unplugin-solid/webpack")({
/* options */
}),
],
};
esbuild
// esbuild.config.js
import { build } from "esbuild";
build({
/* ... */
plugins: [
require("unplugin-solid/esbuild")({
/* options */
}),
],
});
Astro
// astro.config.mjs
import Solid from "unplugin-solid/astro";
export default defineConfig({
integrations: [
Solid({
/* options */
}),
],
});