Search code examples
vitevscode-remote

VSC Remote Server Works with Vite projects?


I can't get a Vite Project up and running on the VSCode remote, node based repositories run perfectly. The servers start but the url for the tunnel doesn't. I am using my computer as server in which vite is installed. Is there any other config needed? Browser Screenshot accesing the tunnel's URL Thanks


Solution

  • Maybe you can try append --host=0.0.0.0 in your package.json file at your dev command like so:

    {
     "name": "your project",
     "version": "0.0.1",
     "scripts": {
      "dev": "vite dev --host=0.0.0.0",
      ...
     },
     ...
    }