Closed Mitchal closed 7 years ago
Alright, I got it! The browser-opening issue in the emulator was solved by adding this to config.xml:
<allow-navigation href="http://10.0.2.2:4200/*" />
I guess I will need another line for each ip-adress my dev machine will have from each device's point of view.
But I still wonder - why is this little 'hack' not mentioned in the docs, and is there a more robust way to deal with it?
Hi @Mitchal, im experiencing this on device as well, did you have to do anything else?
Hi @nicwillemse! Sorry to hear you've been struggling with this as well - I know it can be mighty frustrating. Sadly I don't have any further insights in this than I have shared previously, above.
Hope you'll work it out, and please share any solution here for completeness. :-)
Hi and thanks for a potentially awesome addon!
I am trying to get the very interesting-looking livereload feature to work on my Nexus 4 Android device (real device, not emulator). Here is what I do:
ember new hello
cd hello
ember install ember-cli-cordova
locationType
todefaultLocationType
ember generate cordova-init com.poeticsystems.hello
cd cordova
cordova platform add android
cd ..
cordova.liveReload.enabled = true
,cordova.liveReload.platform = 'android'
andcordova.emberUrl
to my ip on the local networkember cordova:build --platform android
ember serve
ember cordova run android
Expected result: App starts on the device and looks and behaves exactly as before liveReload was enabled, but also gets all changes made in the Ember app immediately without having to rebuild the app.
Actual result: The app starts on the device like normal but also pops open a Chrome browser pointing to the URL specified in
cordova.emberUrl
in config/environment.js. In the Chrome browser window, a couple of weird prompts show up, and after closing them, the app is frozen and seemingly not fully loaded. Upon closing the Chrome browser window, the Cordova app runs normally but does not respond to changes made to the source, i. e. exactly as before enabling liveReload.I hope anyone can help me with this! Thanks!