fix: Add target: esnext by default (#733)

This commit is contained in:
Aaron
2024-06-14 00:25:11 -05:00
committed by GitHub
parent a0d56b4d27
commit 43fcbec0eb
2 changed files with 4 additions and 1 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ Enables the use of [SolidJS](https://www.solidjs.com/) in your web extension, in
This plugin makes a few changes:
1. Adds `vite-plugin-solid` to vite
1. Adds `vite-plugin-solid` to and sets `build.target: esnext` in the vite config
2. Adds the [`solid-js` preset](https://github.com/unjs/unimport/blob/main/src/presets/solid.ts) to auto-imports
## Usage
+3
View File
@@ -10,6 +10,9 @@ export default defineWxtModule<SolidModuleOptions>({
addViteConfig(wxt, () => ({
plugins: [solid(vite)],
build: {
target: 'esnext',
},
}));
addImportPreset(wxt, 'solid-js');