Android run livereload not working

Hello,

I install: npm install -g ionic
and create new project: ionic start TEST blank --v2

When i run application: ionic run android -l and change html content, ionic non recompile html and livereload not work. I have not errors in console.

I try to update: npm install ionic@latest -g and npm install @ionic/app-scripts@latest --save-dev
but i have the same problem.

How can i resolve this issues?

Thank you!!!

I have answered this issue before. And it still persist to this day. You can basically add "run:after":"watch" command in your scripts list in package.json for now.

They dont recommend using live reload. I dont know how am i supposed to develop without livereload anyway. It would be a pain to manually rebuild everytime.

Try it:
ionic run -l -c -s --debug --device

4 Likes

Nope… not working…

Can you tell me how you add this workaround? I am having the same problem!

open up package.json… add “run:after”:“watch” as another entry to “scripts” list…

Note: this will enforce watch regardless whether you use --livereload or not

// package.json
...

"homepage": "http://ionicframework.com/",
  "private": true,
  "scripts": {
    "build": "ionic-app-scripts build",
    "watch": "ionic-app-scripts watch",
    "serve:before": "watch",
    "emulate:before": "build",
    "deploy:before": "build",
    "build:before": "build",
    "run:before": "build",
    "run:after": "watch"
  },
  "dependencies": {
    "@angular/common": "2.1.1",
    "@angular/compiler": "2.1.1",
    "@angular/compiler-cli": "2.1.1",

...
1 Like

hii ,

It’s work for me.

thanks @Natanael4354.

Still now working, i don’t know what happened