Skip to content

server.open fails to add slash before relative path #11188

@milahu

Description

@milahu

Describe the bug

i am doing

npx vite --open index.html

actual result: the relative path is joined with the port number

http://http//localhost:5178index.html

expected result: index.html should have the same meaning as /index.html

http://localhost:5178/index.html

related #5068

Reproduction

-

Steps to reproduce

No response

System Info

npx vite --version 
vite/3.1.7 linux-x64 node-v19.0.0

Used Package Manager

npm

Logs

No response

Validations

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions