I am dealing with SQLite in my ionicframework project.
Every time I change the code in controller, I need to rerun the apps in my phone and see the console.log what was the output.
Anyone knows how to view SQLite in android / ios phone from PC?
It was so hard and takes so much time to make any changes in codes and
to rerun the project to see the result in console.log
Any helps will make my coding faster. Thanks for any helps.
You can use --livereload or -l in run command as mention in ionic cli docs
Run your app using this command
ionic run android -l
or
ionic run android --livereload
Related
I would like to be able to upload/update files from my local machine using real device android.
I've wrote this command line :
ionic cordova run android
from my ionic project folder.
I can see my app on the real device but when i update a file from the project folder, i can't see the result in the real device.
If i want to see the change i have to re-run android.
Is there a way without android studio to be able to see the changes after editing a file in the ionic project'folder ?
You need to build every time on mobile, you can run your application on browser if you want to see the results after editings.
Finaly i had to run this command and the local machine folder reflect the real device app :
ionic cordova run android --livereload -cs
I'm new in phoneGap and have problem to debug my app, I know that exist a lot of post about this but really I don't have idea how make this work.
I have console.log("message") in severals part of my code; but how can see this message when run my app?
I use this command to run
phonegap build android
phonegap run android --target=G7T7N16A26000893 --debug
with this result
with this not terminal still open to see anything. Aditional I try with Chroome DevsTools; but look that is only for pages not for apps.
Thanks #Kerri Shotts you are rigth, with google in remote devices could see apps, full tutorial her
i am using https://github.com/NathanWalker/angular2-seed-advanced which creates a running nativescript app.
now, i am a starter with nativescript and wanted to ask, how i can achieve a good development flow.
i am coming from ionic where i was able to see the console output on my development machine and was able to test my app live on a cable connected device. live reloading was running also.
so my questions:
can i run my app on a device without publishing it to the store
will i be able to see the console.log output somehow on my local dev machine with adb or a nativescript cli command?
is live reloading possible for developing nativescript apps?
Thank you in advance!
yes
yes
yes
tns livesync android --watch
You can install the app to your own Android / iOS real devices and/or the iOS simulator and Android emulators, all without sending it to any of the stores.
You can see the log fine, typically when you do a tns run [ios|android] the log is pipped back to your console. You can also run the standard adb logcat (android) or idevicesyslog (for iOS if installed)
Live reloading is possible, and works fairly well. You can use the tns run [android|ios] which is built into the tns command line.
The answer to all three questions is yes (as another answer point out). To add to answer of question 3,
As of nativescript version 2.5.0, tns run and tns livesync does the same thing, tns run has the ability to apply changes and sync it to a running app on device/emulator. The message on console clearly says tns livesync is being deprecated, so you should always look to use tns run
Here are the latest options(As of 2018-Jan) to run the app in live sync mode with a device when you are using NathanWalker -angular-seed-advanced.
iOS (device): npm run start.ios.device --debug
Android (device): npm run start.android.device --debug
--debug option will pull in more logs from the device(not just for your app, but also other activities)
Check the latest doc here for up-to date commands,
You can also use adb as explained here,
I have an ionic project and I want to test it on my device.
I've seen some tutorial and I id like this :
ionic platform add android
and then
ionic run android
but it opens the emulator and I cannot see my application.
My main goal is to export it on my phone,in order to test it.
Can you help me?
Thank you!
Run ionic run android --device
Note: Be sure that USB-Debugging is enabled on your device in
developer options.
Also to make sure your device is authorised you can run:
adb devices
I got stuck when trying to create my first PhoneGap application. I entered
cordova create hello com.example.hello HelloWorld in the command line and got this text:
Downloading cordova library for www...
I waited some minutes, but libraries didn't load. I guess it's a common problem for beginners.
Please, help me solve this problem and let me go further. Thanks a lot. :)
In the PhoneGap documentation, they state that it may take a while to create the app.
"It may take some time for the command to complete, so be patient. Running the command with the -d option displays information about its progress."
Try this:
$ cordova create hello com.example.hello HelloWorld -d
You can see the progress.