We have a requirement of creating a container app using an ionic framework for android and iOS. On launching this container app, it should directly show a responsive webpage inside the native wrapper(review).I have used the below command for creating the ionic project.
sudo ionic start newApp blank --type angular
Now I am confused about below version details.
Ionic:
Ionic CLI : 6.11.7 (/usr/local/lib/node_modules/#ionic/cli)
Ionic Framework : #ionic/angular 5.3.2
#angular-devkit/build-angular : 0.1000.8
#angular-devkit/schematics : 10.0.8
#angular/cli : 10.0.8
#ionic/angular-toolkit : 2.3.3
Utility:
cordova-res : not installed
native-run : not installed
System:
NodeJS : v12.18.3 (/usr/local/bin/node)
npm : 6.14.6
OS : macOS Catalina
My Doubts:
ionic/angular 5.3.2, does that mean ionic version is 5.3.2 or is that angular version.
Also is that angularJS or Angular 8/7/9/etc.
To Answer your doubts :
The 5.3.2 version is the Ionic Version
It is angular 10 you are using
Yes, with ionic info you can find in the Ionic Framework field indicates the version that the project is using, in your case is 5.3.2 version
To get the version of angular you can go into node_modules/#angular/core/package.json and check version field
Or you should install the angular client and run ng --version which will indicate which version of angular you are using in the project in field Angular
Related
i am trying to build an app working with offline map using mbtiles from openmaptiles and mapbox. i have followed this link : GitHub - oscarfonts/mapbox-gl-cordova-offline: Offline vector maps in Cordova using Mapbox GL JS and it was working fine with API 29 (cordova) but with API 30 (capacitor) i have this error :
ERROR Error: Uncaught (in promise): Error: cordova-sqlite-ext plugin not available. Please install the plugin and make sure this code is run after onDeviceReady event
I have used npm i cordova-sqlite-ext but i still have the same error can anybody help
this is my ionic info
Ionic:
Ionic CLI : 6.17.1 (C:\Users\SAH\AppData\Roaming\npm\node_modules#ionic\cli)
Ionic Framework : #ionic/angular 5.9.1
#angular-devkit/build-angular : 12.1.4
#angular-devkit/schematics : 12.1.4
#angular/cli : 12.1.4
#ionic/angular-toolkit : 4.0.0
Capacitor:
Capacitor CLI : 3.3.2
#capacitor/android : 3.3.2
#capacitor/core : 3.3.2
#capacitor/ios : not installed
Utility:
cordova-res : 0.15.3
native-run : 1.5.0
System:
NodeJS : v14.17.6 (C:\Program Files\nodejs\node.exe)
npm : 6.14.15
OS : Windows 10
Thanks
I just upgraded capacitor to 3.2.x and when I try to build my Ionic project, almost no capacitor function seems to work. For example, I get errors like:
Uncaught TypeError: cap.nativeCallback is not a function
...
Uncaught TypeError: Capacitor.createEvent is not a function
...
package com.getcapacitor.annotation does not exist
Here's my Ionic Info:
Ionic:
Ionic CLI : 6.17.1 (/usr/local/lib/node_modules/#ionic/cli)
Ionic Framework : #ionic/angular 5.5.2
#angular-devkit/build-angular : 0.1000.8
#angular-devkit/schematics : 10.0.8
#angular/cli : 10.0.8
#ionic/angular-toolkit : 2.3.3
Capacitor:
Capacitor CLI : 3.2.3
#capacitor/android : 3.0.0-beta.3
#capacitor/core : 3.2.3
#capacitor/ios : not installed
Cordova:
Cordova CLI : 10.0.0
Cordova Platforms : android 9.1.0
Cordova Plugins : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.2.1, (and 9 other plugins)
Utility:
cordova-res : 0.15.3
native-run : 1.4.1
System:
Android SDK Tools : 26.1.1 (/home/che-azeh/Android/Sdk)
NodeJS : v12.21.0 (/usr/bin/node)
npm : 7.5.2
OS : Linux 5.11
Here was the problem: if you look at the capacitor section under my Ionic Info, you'd notice an incosistency between Capacitor CLI, #capaciotr/core and #capacitor/android:
Capacitor:
Capacitor CLI : 3.2.3
#capacitor/android : 3.0.0-beta.3
#capacitor/core : 3.2.3
So what I did was upgrade all 3 to their latest versions:
npm install #capacitor/cli#latest #capacitor/core#latest
npm install #capacitor/android#latest
Now, it looks ike:
Capacitor:
Capacitor CLI : 3.2.3
#capacitor/android : 3.2.3
#capacitor/core : 3.2.3
Finally, I remove the Android folder created by capacitor (rm -R ./android), reinitialize capacitor (npx cap init) rebuild ionic project (ionic build android) and then npx cap add android.
And solved! Zero errors!
When I run Ionic 4 app, the browser shows api data but when i run same app on android device it doen't shows api data.
I am using Laravel as a backend, from where i am fetching api data.
The Ionic info is -
Ionic:
Ionic CLI : 6.5.0 (C:\Users\LENOVO\AppData\Roaming\npm\node_modules\#ionic\cli)
Ionic Framework : #ionic/angular 4.1.1
#angular-devkit/build-angular : 0.803.26
#angular-devkit/schematics : 8.3.26
#angular/cli : 8.3.26
#ionic/angular-toolkit : 2.2.0
Cordova:
Cordova CLI : not installed
Cordova Platforms : android 7.1.4
Cordova Plugins : cordova-plugin-ionic-keyboard 2.2.0, cordova-plugin-ionic-webview 4.1.3, (and 4 other plugins)
Utility:
cordova-res : not installed
native-run : 1.0.0
System:
NodeJS : v12.16.1 (C:\Program Files (x86)\nodejs\node.exe)
npm : 6.13.4
OS : Windows 10
I am really stuck here...
Your Problem is Cors you can install middleware in laravel to avoide the problem
Or you can test your application in the chrome disable securite
Try to Run :
chrome.exe --user-data-dir="C://Chrome dev session" --disable-web-security
and test your application in this chrome and let me khnow
I'm working on an Ionic tutorial that was developed under Ionic 3, and I'm having trouble creating my blank project with the right version of the framework, it defaults to Ionic 4.
How can I get it to create my project as Ionic 3 (e.g., Ionic Framework: ionic-angular 3.9.2)?
C:\workbench\>ionic start myProject blank
[..]
C:\workbench\>cd myProject
C:\workbench\myProject> ionic info
[..]
Ionic:
ionic (Ionic CLI) : 4.10.0 (C:\Users\myhome\AppData\Roaming\npm\
node_modules\ionic)
Ionic Framework : #ionic/angular 4.0.0
#angular-devkit/build-angular : 0.12.3
#angular-devkit/schematics : 7.2.3
#angular/cli : 7.2.3
#ionic/angular-toolkit : 1.3.0
[..]
How do I get 3.x?
You don't use the actual version number to specify the frame work.
Instead you need to used the --type=<type> option.
<type> can be at least one of the following:
ionic1 - which will get you ionic1 1.3.4
ionic-angular - which will get you ionic-angular 3.9.2
angular - which will get you ionic/angular 4.0.0
There may be other's but I haven't encountered them yet.
In this particular case, the command would be: ionic start myProject blank --type=ionic-angular
I'm trying to upload the App I built to my Ionic Pro account.
I've linked my account and added the SSH keys but after running ionic upload I'm getting this error
[ERROR] Sorry! The configured backend (pro) does not know about ionic upload.
This is My Ionic Info
cli packages: (/home/jos/Desktop/helloapp/node_modules)
#ionic/cli-utils : 1.9.2
ionic (Ionic CLI) : 3.9.2
global packages:
Cordova CLI : 7.0.1
Gulp CLI : not installed globally
local packages:
Cordova Platforms : android 6.2.3 browser 4.1.0
Ionic Framework : ionic1 1.3.1
System:
Android SDK Tools : 26.0.2
Node : v6.11.0
npm : 3.10.10
OS : Linux 3.13
ionic upload doesn't work with backend pro, you have to create an app
on https://dashboard.ionicjs.com/apps and there will be a setup guide :)