Ionic 2 runs on emulator but not in real device - ionic-framework

I have install ionic 2 template application.
On emulator application runs OK, but on actual device android 4.1.2 I see only white screen.
I have try to debug app with ionic run android --consolelogs --livereload but i don't see any error.
What behavior are you expecting?
Application should run on my real android 4.1.2 (LG-E440) device.
Steps to reproduce:
Follow instructions: http://ionicframework.com/docs/v2/getting-started/installation/
Take 4.1.2 Android and try to run application.
Application should show only white screen...
Ionic info:
Cordova CLI: 6.0.0
Gulp version: CLI version 3.9.1
Gulp local: Local version 3.9.1
Ionic Version: 2.0.0-beta.3
Ionic CLI Version: 2.0.0-beta.19
Ionic App Lib Version: 2.0.0-beta.9
OS: Distributor ID: Ubuntu Description: Ubuntu 14.04.3 LTS
Node Version: v5.3.0

Related

Ionic 2 - Progressive Web App Only - How-to?

Since I only need a Progressive Web App; I was wondering if it's possible to not install Cordova as well as everything that is related to native apps when installating/setting up Ionic?
Do you think we could get rid of what is in bold? (see below after
doing an ionic info command)
Do you have any thoughts / best
practices to share?
The following components are part of Ionic or are needed
Cordova CLI: 6.5.0
Ionic CLI Version: 2.2.1
Ionic App Lib Version: 2.2.0
ios-deploy version: 1.9.0
ios-sim version: 5.0.13
OS: OS X El Capitan Node Version: v7.0.0
Xcode version: Xcode
8.2.1 Build version 8C1002
npm run ionic:build --prod
Just follow the instructions
https://www.gitbook.com/book/jgw96/ionic-pwa/details

ionic 1, I lost my app's icons and splashscreen

I am running my app on my phone this morning with
ionic run android -lcs
as usual ! But this morning the icon and splashscreen switched to default images !
Any idea how to get back to normal ?
Thanks
$ ionic info
Your system information:
Cordova CLI: 6.4.0
Ionic CLI Version: 2.2.1
Ionic App Lib Version: 2.2.0
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Linux 4.4
Node Version: v7.4.0
Xcode version: Not installed
Try to force update the android platform to version 6.1.0:
cordova platform update android#6.1.0
The current version (6.0.0) has a bug that causes this problem.
EDIT:
Cordova 6.5.0 has been released recently. This release updates cordova-android to version 6.1.1. So best solution now is:
npm install -g cordova

Ionic link does not work with Ionic v2

When I run ionic link command inside ionic project folder I got following error message
"You cannot run this command unless you are in an Ionic Project folder"
My system info.
Cordova CLI: 6.3.1
Gulp version: CLI version 1.2.1
Gulp local: Local version 3.9.1
Ionic Framework Version: 2.0.0-beta.11
Ionic CLI Version: 2.0.0-beta.36
Ionic App Lib Version: 2.0.0-beta.19
OS: Distributor ID: Ubuntu Description: Ubuntu 14.04.4 LTS
Node Version: v6.4.0
You can use following command to setup app linking with Ionic IO.
ionic io init
this will update ionic.config.json with app_id and generate .io-config.json file with app_id and api_key.
ionic io init
is no longer available in cli 3. Create a new app from apps.ionic.io dashboard and then run
ionic link
which will list down apps from your ionic.io account and let you choose an app to which you want to link your local app. You have to run 'ionic login' if you haven't done so already.

if i update cordova to a newer version is it necessary to update ionic and all other plugins? how does the changes effect?

I have updated cordova and all other plugins. When I tried generating apk, its showing
"doesnot have required environment or OS to install"
I am not able figure out where the problem is.
this is version info of my app..
Cordova CLI: 6.0.0
Gulp version: CLI version 3.9.0
Gulp local: Local version 3.9.0
Ionic Version: 1.0.0
Ionic CLI Version: 1.7.7
Ionic App Lib Version: 0.6.3
OS: Windows 7
Node Version: v0.12.7
Did you tried removing Android platform?
ionic platform remove android
and then add it again:
ionic platform add android
or maybe this can be useful:
Cordova / Ionic build error (sometimes): don't have required environment

crosswalk-lite in ionic cli v1.4.4 does not reduce apk size

Tried many times, the apk file size does not change.
ionic revert android;
ionic browser add crosswalk-lite
ionic build android
I also tried remove android platform and do from scratch, but never suceeded.
Your system information:
Cordova CLI: 5.0.0
Gulp version: CLI version 3.8.11
Gulp local: Local version 3.8.11
Ionic CLI Version: 1.4.4
Ionic App Lib Version: 0.0.20
OS: Distributor ID: Ubuntu Description: Ubuntu 12.04.5 LTS
Node Version: v0.12.3
Same here.
I guess crosswalk-lite is so new that ionic still doesn't quite cope with it. Or it did, but things have changed now.
When I run:
ionic browser remove crosswalk
ionic browser remove crosswalk-lite
ionic browser add crosswalk-lite
I get this ionic.projectfile:
{
"name": "chapter5",
"app_id": "27fa0870",
"browsers": [
{
"platform": "android",
"browser": "crosswalk-lite",
"version": "12.41.296.5"
}
]
}
ionic info output:
Cordova CLI: 4.2.0
Gulp version: CLI version 3.8.11
Gulp local:
Ionic Version: 1.0.0-rc.0
Ionic CLI Version: 1.4.5
Ionic App Lib Version: 0.0.22
OS: Distributor ID: Fedora Description: Fedora release 21
(Twenty One)
Node Version: v0.10.36
Also, take notice of your cordova-android version, when you run browser add:
Android project created with cordova-android#4.0.0-dev
And your cordova-crosswalk-engine. Mine says: c0.7.1
Those are all inter-related and may lead to weird errors.