Live Reload not working in Remote Window (WSL)
See original GitHub issueI’m submitting a…
[x ] Regression (a behavior that used to work and stopped working in a new release)
[x ] Bug report <!-- Please search GitHub for a similar issue or PR before submitting -->
[ ] Feature request
[ ] Documentation issue or request
[ ] Other: <!-- Please describe: -->
Current behavior
When using VS Code as a remote window connected to WSL (Ubuntu 18.04) the live reload feature of Live Server does not work.
Expected behavior
Live reload to work as it does when not in a remote window connected to WSL.
Environment
Browser:
- [x] Chrome (desktop) version 80.0.3987.163
- [ ] Firefox version XX
- [ ] Safari (desktop) version XX
- [ ] IE version XX
- [ ] Edge version XX
For Tooling issues:
- Live Server: 5.6.1 <!-- Check which version is installed -->
- Platform: Windows | Ubuntu 18.04 WSL <!-- Mac, Linux, Windows -->
- Visual Studio Code: 1.45.0-insider <!-- `code --version` -->
Others
When not using a remote window, the live reload feature works.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:23
- Comments:16
Top Results From Across the Web
Live Server extension is not auto-reloading with WSL2
It seems WSL doesn't support live reload if the file is in another OS. Please refer the GitHub issue. The solution is to...
Read more >Developing in WSL - Visual Studio Code
See the Remote Development and Linux article for details. Install Visual Studio Code on the Windows side (not in WSL).
Read more >Remote WSL connection doesn't update Vue.js app on code ...
Create a new Vue.js project (or anything that support live reloading); Use WSL node.js instead of ... Haven't seen this problem when using...
Read more >Livereload option not working on Windows 10 - Jekyll Talk
So, when starting the server : bundle exec jekyll serve --trace --livereload Configuration file: C:/Github/myrepo2/_config.yml Theme Config file ...
Read more >Troubleshooting Windows Subsystem for Linux | Microsoft Learn
File a new issue. If you have found a problem with WSL and there does not appear to be an existing issue, you...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
To fix this issue go to Settings make sure you’re under Remote[WSL:“your linux distro”] and modify the Live Server>Settings: Advance Custom Browser CMD Line click edit in settings.json it should look like this: “liveServer.settings.AdvanceCustomBrowserCmdLine”: “/mnt/c/Program Files/Google/Chrome/Application/chrome.exe” change the path a needed for Firefox, Edge etc.
It seems the extension is looking within the OS for the browser as installing linux chrome also works, but under wsl its not too good so Id suggest th above fix or maybe adding chrome to the path for linux
Based on this answer, i’ve prepared the config to support 1 browser, you just need to uncomment your preffered browser:
Note - To reach the Opera browsers just rename
<<USERNAME>>
with your current username. Note² - The Firefox folder may vary depending on the source you’ve installed.