question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

feat: add a "live reload flag"

See original GitHub issue

Feature Request

Ionic version: [x] 4.7.1

Describe the Feature Request Provide a way to determine when we are running Ionic using the --livereload flag.

Describe Preferred Solution When we are using the --livereload flag to debug the an in a Device, a way to recognize this should be available either with a platform.isLiveReload() or an window.isIonicLiveReload flag.

Describe Alternatives For ionic 3 I was snipping the URL for see if localhost is not present. It does not work anymore. Other options where to look into the window object for an IonicDevServer object. It does not work anymore.

As current workaround I am making a proxy of the WebSocket class to check when a connection is made. I wanted to put that code in a PR but I didn’t knew in which file should I do it.

Additional Context Some functionality needs workarounds or other way to handle. Example: Load media files from the device internal storage will throw CORS errors in livereload.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
sruthakeerthikotlacommented, Mar 8, 2020

Can this please be merged soon? It would help us implement a feature that we are using right now.

0reactions
ionitron-bot[bot]commented, Apr 9, 2020

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Live Reload | Ionic Documentation
One option that can boost productivity when building Ionic apps is Live Reload (or live-reload). When active, Live Reload will reload the browser...
Read more >
A complete guide to full-stack live reload - LogRocket Blog
Project setup; Implementing live reload with Node.js and nodemon; Live reload with nodemon and TypeScript; Automated JavaScript testing with ...
Read more >
Flutter Hot Reload - Medium
Introduction. One of Flutter's great features is hot reload. You press r on your keyboard, and moments later the impact of your changes...
Read more >
Untitled
To get hot reloading working with React we have to install ... Skipping the --hot flag and going through webpack configuration gives more...
Read more >
How to Stop Auto-Reload/Refresh in Chrome Browser Tabs?
Toggle off Auto Discardable. It is a new addition to Chrome, which I believe was introduced during the automatic tab discarding the chrome...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found