fix: Add WASM files to Vite Allow List and change devPath to localhost to fix Web Example (#5560)

Co-authored-by: Ben Wishovich <ben@benw.is>
This commit is contained in:
Ben Wishovich 2022-11-06 11:26:27 -08:00 committed by GitHub
parent 777c086590
commit 878421beb7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -2,7 +2,7 @@
"build": {
"beforeBuildCommand": "yarn build:tauri",
"beforeDevCommand": "yarn dev:tauri",
"devPath": "http://127.0.0.1:5173",
"devPath": "http://localhost:5173",
"distDir": "../../build"
},
"package": {

View File

@ -25,6 +25,12 @@ if (TARGET === 'web') {
}
const config: UserConfig = {
server: {
fs: {
// Allow serving the wasm file from this folder.
allow: ['.']
}
},
plugins,
resolve: {
alias: {