22
33[ ![ NPM version] ( https://img.shields.io/npm/v/unplugin-vue-jsx-vapor?color=a1b858&label= )] ( https://www.npmjs.com/package/unplugin-vue-jsx-vapor )
44
5- Starter template for [ unplugin] ( https://github.com/unjs/unplugin ) .
6-
7- ## Template Usage
8-
9- To use this template, clone it down using:
10-
11- ``` bash
12- npx degit unplugin/unplugin-vue-jsx-vapor my-unplugin
13- ```
14-
15- And do a global replacement of ` unplugin-vue-jsx-vapor ` with your plugin name.
16-
17- Then you can start developing your unplugin 🔥
18-
19- To test your plugin, run: ` pnpm run dev `
20- To release a new version, run: ` pnpm run release `
5+ Convert JSX to Template for compiler-vapor.
216
227## Install
238
@@ -30,11 +15,13 @@ npm i unplugin-vue-jsx-vapor
3015
3116``` ts
3217// vite.config.ts
33- import Starter from ' unplugin-vue-jsx-vapor/vite'
18+ import VueJsxVapor from ' unplugin-vue-jsx-vapor/vite'
3419
3520export default defineConfig ({
3621 plugins: [
37- Starter ({ /* options */ }),
22+ VueJsxVapor ({
23+ /* options */
24+ }),
3825 ],
3926})
4027```
@@ -48,18 +35,19 @@ Example: [`playground/`](./playground/)
4835
4936``` ts
5037// rollup.config.js
51- import Starter from ' unplugin-vue-jsx-vapor/rollup'
38+ import VueJsxVapor from ' unplugin-vue-jsx-vapor/rollup'
5239
5340export default {
5441 plugins: [
55- Starter ({ /* options */ }),
42+ VueJsxVapor ({
43+ /* options */
44+ }),
5645 ],
5746}
5847```
5948
6049<br ></details >
6150
62-
6351<details >
6452<summary >Webpack</summary ><br >
6553
@@ -68,8 +56,10 @@ export default {
6856module .exports = {
6957 /* ... */
7058 plugins: [
71- require (' unplugin-vue-jsx-vapor/webpack' )({ /* options */ })
72- ]
59+ require (' unplugin-vue-jsx-vapor/webpack' )({
60+ /* options */
61+ }),
62+ ],
7363}
7464```
7565
@@ -82,7 +72,12 @@ module.exports = {
8272// nuxt.config.js
8373export default defineNuxtConfig ({
8474 modules: [
85- [' unplugin-vue-jsx-vapor/nuxt' , { /* options */ }],
75+ [
76+ ' unplugin-vue-jsx-vapor/nuxt' ,
77+ {
78+ /* options */
79+ },
80+ ],
8681 ],
8782})
8883```
@@ -99,7 +94,9 @@ export default defineNuxtConfig({
9994module .exports = {
10095 configureWebpack: {
10196 plugins: [
102- require (' unplugin-vue-jsx-vapor/webpack' )({ /* options */ }),
97+ require (' unplugin-vue-jsx-vapor/webpack' )({
98+ /* options */
99+ }),
103100 ],
104101 },
105102}
@@ -113,10 +110,10 @@ module.exports = {
113110``` ts
114111// esbuild.config.js
115112import { build } from ' esbuild'
116- import Starter from ' unplugin-vue-jsx-vapor/esbuild'
113+ import VueJsxVapor from ' unplugin-vue-jsx-vapor/esbuild'
117114
118115build ({
119- plugins: [Starter ()],
116+ plugins: [VueJsxVapor ()],
120117})
121118```
122119
0 commit comments