File tree 1 file changed +4
-4
lines changed
packages/@vue/cli-service/lib/commands
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -127,9 +127,10 @@ module.exports = (api, options) => {
127
127
128
128
// inject dev & hot-reload middleware entries
129
129
if ( ! isProduction ) {
130
+ const sockPath = projectDevServerOptions . sockPath || '/sockjs-node'
130
131
const sockjsUrl = publicUrl
131
132
// explicitly configured via devServer.public
132
- ? `?${ publicUrl } /sockjs-node `
133
+ ? `?${ publicUrl } &sockPath= ${ sockPath } `
133
134
: isInContainer
134
135
// can't infer public network url if inside a container...
135
136
// use client-side inference (note this would break with non-root publicPath)
@@ -138,9 +139,8 @@ module.exports = (api, options) => {
138
139
: `?` + url . format ( {
139
140
protocol,
140
141
port,
141
- hostname : urls . lanUrlForConfig || 'localhost' ,
142
- pathname : '/sockjs-node'
143
- } )
142
+ hostname : urls . lanUrlForConfig || 'localhost'
143
+ } ) + `&sockPath=${ sockPath } `
144
144
const devClients = [
145
145
// dev server client
146
146
require . resolve ( `webpack-dev-server/client` ) + sockjsUrl ,
You can’t perform that action at this time.
0 commit comments