Skip to content

Commit 90c2739

Browse files
committed
fix: 避免開發時遭遇 CORS 問題
1 parent f66181a commit 90c2739

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

vite.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ import path from 'path'
88
import { v4wp } from '@kucrut/vite-for-wp'
99

1010
export default {
11+
server: {
12+
cors: true
13+
},
1114
plugins: [
1215
alias(),
1316
react(),

0 commit comments

Comments
 (0)