Skip to content

Commit 1464221

Browse files
committed
fix: CORS 配置开发服务器代理转发 Mock.Radom.image
1 parent 9f00700 commit 1464221

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

vue2/sandboxs/vue.config.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,11 @@ module.exports = {
88
target: 'https://github.com',
99
changeOrigin: true,
1010
secure: true
11+
},
12+
'/api/image': {
13+
target: 'http://dummyimage.com',
14+
changeOrigin: true,
15+
pathRewrite: { '^/api/image': '' }
1116
}
1217
}
1318
}

0 commit comments

Comments
 (0)