ionic-cli: Live reload doesn't work
Description:
ionic serve
or ionic serve -r
or ionic serve --livereload-port
doesnt refresh the build when any HTML or ts file is changed
Steps to Reproduce:
Do ionic serve
and change any html or ts file
Example repo: N/A
My ionic info
:
cli packages: (/usr/local/lib/node_modules)
@ionic/cli-utils : 1.9.2
ionic (Ionic CLI) : 3.9.2
global packages:
Cordova CLI : 7.0.1
local packages:
@ionic/app-scripts : 2.1.4
Cordova Platforms : browser 4.1.0
Ionic Framework : ionic-angular 3.6.0
System:
Android SDK Tools : 26.0.2
Node : v8.4.0
npm : 5.3.0
OS : Linux 4.10
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 24 (8 by maintainers)
@dwieeb , Thanks for your quick response. Actually, I am working on multiple projects(most of them are complex, but have same problem). Of course, they don’t include spaces in paths. I am sure it works well on the empty project.
This will be the steps to reproduce it:
ionic serve
src/
, andlive reload
is working and should show latest updates, but it sometimes shows old version before I changed. This makes me to forceionic serve
and try again. Any problem withcache data
?PS: I am using
ionic cli@latest
because it asks me to update everyday before I start to work.Just learned about Stencil and when using demo found that I have error from node.js ENOSPC (not enough space on the drive but I have more than need)
After that I just looked at different issues and found this one:
And after that livereload again works for project that before has no reaction.
@sdey0081 From what you’ve described, my guess is you’re experiencing an issue with your service worker. To verify, in Chrome debugger, go to Application -> Service Workers and click
stop
. You should also comment out the service worker in yoursrc/index.html
to disable it and verify that live reload is working without it.If you’re new to service workers, you can check out these articles: