-
-
Notifications
You must be signed in to change notification settings - Fork 6.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(create-app): Use @preact/preset-vite for Preact templates (#2488)
- Loading branch information
1 parent
73b80d5
commit c433236
Showing
4 changed files
with
10 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
import { defineConfig } from 'vite' | ||
import preactRefresh from '@prefresh/vite' | ||
import preact from '@preact/preset-vite' | ||
|
||
// https://vitejs.dev/config/ | ||
export default defineConfig({ | ||
esbuild: { | ||
jsxFactory: 'h', | ||
jsxFragment: 'Fragment', | ||
jsxInject: `import { h, Fragment } from 'preact'` | ||
}, | ||
plugins: [preactRefresh()] | ||
plugins: [preact()] | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
import { defineConfig } from 'vite' | ||
import preactRefresh from '@prefresh/vite' | ||
import preact from '@preact/preset-vite' | ||
|
||
// https://vitejs.dev/config/ | ||
export default defineConfig({ | ||
esbuild: { | ||
jsxFactory: 'h', | ||
jsxFragment: 'Fragment', | ||
jsxInject: `import { h, Fragment } from 'preact'` | ||
}, | ||
plugins: [preactRefresh()] | ||
plugins: [preact()] | ||
}) |