We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2059319 commit 57276b7Copy full SHA for 57276b7
packages/vite/src/node/preview.ts
@@ -161,7 +161,7 @@ export async function preview(
161
openBrowser(
162
path.startsWith('http')
163
? path
164
- : `${protocol}://${hostname.name}:${serverPort}${path}`,
+ : new URL(path, `${protocol}://${hostname.name}:${serverPort}`).href,
165
true,
166
logger,
167
)
packages/vite/src/node/server/index.ts
@@ -679,7 +679,7 @@ async function startServer(
679
680
681
682
683
684
server.config.logger,
685
0 commit comments