Skip to content

Commit 90e670a

Browse files
committed
Proxy http-server in dev mode
1 parent a6b6e3e commit 90e670a

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

webpack.dev.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@ module.exports = {
1313
port: 9000,
1414
hot: true,
1515
open: true,
16+
proxy: [{
17+
'/music': {
18+
target: 'http://localhost:8080',
19+
changeOrigin: true,
20+
pathRewrite: { '^/music': '' }, // Optional: remove `/music` prefix if needed
21+
},
22+
}],
1623
},
1724
module: {
1825
rules: [

0 commit comments

Comments
 (0)