Skip to content

Commit 093510f

Browse files
committed
Update webpack-dev-server config so it's compatible with both v4 and v5.
1 parent 564c62f commit 093510f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

drupal/web/themes/react_example_theme/webpack.config.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ const config = {
5151
writeToDisk: true,
5252
},
5353
// Settings for http-proxy-middleware.
54-
proxy: {
55-
'/': {
54+
proxy: [
55+
{
5656
index: '',
57-
context: () => true,
57+
context: ['/'],
5858
target: PROXY,
5959
publicPath: PUBLIC_PATH,
6060
secure: false,
@@ -64,7 +64,7 @@ const config = {
6464
changeOrigin: true,
6565
xfwd: true
6666
}
67-
}
67+
]
6868
},
6969
};
7070

0 commit comments

Comments
 (0)