vscode live Server port settings not work, and always open in localhost:8081

5.7k Views Asked by At

here is my live Server settings json

{
    "editor.fontSize": 18,
    "workbench.iconTheme": "vscode-icons",
    "files.autoSave": "onFocusChange",
    "terminal.integrated.shell.windows": "C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
    "explorer.confirmDelete": false,
    "editor.tabCompletion": "on",
    "editor.tabSize": 2,
    "vetur.format.options.useTabs": true,
    "editor.detectIndentation": false,
    "git.autofetch": false,
    "liveServer.settings.host": "localhost",
    "liveServer.settings.port": 0,

}

I try to reinstall live Server and close the windows firewall, but it still not work.

It drives me mad!

1

There are 1 best solutions below

2
higsx On

Look at your workspace , in the .vscode/settings.json ,you may find the "liveServer.settings.port":8081 in it. Just delete it