Check this --> https://forum.ionicframework.com/t/how-to-disable-input-form-validation/54666
Enjoy Coding
Check this --> https://forum.ionicframework.com/t/how-to-disable-input-form-validation/54666
Enjoy Coding
Hi All,
I am using Ionic3. I am trying to create a custom icon and splash screen for my app. I created an icon.png
(432x193) and splash.png
(6135x2733) in the resources
folder.
I then run:
ionic cordova resources
✔ Collecting resource configuration and source images - done!
✔ Uploading source images to prepare for transformations - done!
✔ Generating platform resources: 38 / 38 complete - done!
✔ Modifying config.xml to add new image resources - done!
If I check resources/android/icon
:
and resources/android/splash
:
I can see the new images have been generated (I have <preference name="orientation" value="portrait"/>
, so I think that's why only portrait images are generated, landscape has the default ionic ones).
I also check:
config.xml
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<widget id="com.ionicframework.thewhozoo912107" version="0.0.1" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0">
<name>theWhoZoo</name>
<description>An awesome Ionic/Cordova app.</description>
<author email="admin@thewhozoo.com" href="http://thewhozoo.com/">theWhoZoo Team</author>
<content src="index.html"/>
<access origin="*"/>
<allow-intent href="http://*/*"/>
<allow-intent href="https://*/*"/>
<allow-intent href="tel:*"/>
<allow-intent href="sms:*"/>
<allow-intent href="mailto:*"/>
<allow-intent href="geo:*"/>
<allow-intent href="*"/>
<platform name="android">
<allow-intent href="market:*"/>
<icon src="resources/android/icon/drawable-ldpi-icon.png" density="ldpi"/>
<icon src="resources/android/icon/drawable-mdpi-icon.png" density="mdpi"/>
<icon src="resources/android/icon/drawable-hdpi-icon.png" density="hdpi"/>
<icon src="resources/android/icon/drawable-xhdpi-icon.png" density="xhdpi"/>
<icon src="resources/android/icon/drawable-xxhdpi-icon.png" density="xxhdpi"/>
<icon src="resources/android/icon/drawable-xxxhdpi-icon.png" density="xxxhdpi"/>
<splash src="resources/android/splash/drawable-port-ldpi-screen.png" density="port-ldpi"/>
<splash src="resources/android/splash/drawable-port-mdpi-screen.png" density="port-mdpi"/>
<splash src="resources/android/splash/drawable-port-hdpi-screen.png" density="port-hdpi"/>
<splash src="resources/android/splash/drawable-port-xhdpi-screen.png" density="port-xhdpi"/>
<splash src="resources/android/splash/drawable-port-xxhdpi-screen.png" density="port-xxhdpi"/>
<splash src="resources/android/splash/drawable-port-xxxhdpi-screen.png" density="port-xxxhdpi"/>
</platform>
<platform name="ios">
<allow-intent href="itms:*"/>
<allow-intent href="itms-apps:*"/>
<icon src="resources/ios/icon/icon.png" width="57" height="57"/>
<icon src="resources/ios/icon/icon@2x.png" width="114" height="114"/>
<icon src="resources/ios/icon/icon-40.png" width="40" height="40"/>
<icon src="resources/ios/icon/icon-40@2x.png" width="80" height="80"/>
<icon src="resources/ios/icon/icon-40@3x.png" width="120" height="120"/>
<icon src="resources/ios/icon/icon-50.png" width="50" height="50"/>
<icon src="resources/ios/icon/icon-50@2x.png" width="100" height="100"/>
<icon src="resources/ios/icon/icon-60.png" width="60" height="60"/>
<icon src="resources/ios/icon/icon-60@2x.png" width="120" height="120"/>
<icon src="resources/ios/icon/icon-60@3x.png" width="180" height="180"/>
<icon src="resources/ios/icon/icon-72.png" width="72" height="72"/>
<icon src="resources/ios/icon/icon-72@2x.png" width="144" height="144"/>
<icon src="resources/ios/icon/icon-76.png" width="76" height="76"/>
<icon src="resources/ios/icon/icon-76@2x.png" width="152" height="152"/>
<icon src="resources/ios/icon/icon-83.5@2x.png" width="167" height="167"/>
<icon src="resources/ios/icon/icon-small.png" width="29" height="29"/>
<icon src="resources/ios/icon/icon-small@2x.png" width="58" height="58"/>
<icon src="resources/ios/icon/icon-small@3x.png" width="87" height="87"/>
<splash src="resources/ios/splash/Default-568h@2x~iphone.png" width="640" height="1136"/>
<splash src="resources/ios/splash/Default-667h.png" width="750" height="1334"/>
<splash src="resources/ios/splash/Default-736h.png" width="1242" height="2208"/>
<splash src="resources/ios/splash/Default-Portrait@2x~ipad.png" width="1536" height="2048"/>
<splash src="resources/ios/splash/Default-Portrait@~ipadpro.png" width="2048" height="2732"/>
<splash src="resources/ios/splash/Default-Portrait~ipad.png" width="768" height="1024"/>
<splash src="resources/ios/splash/Default@2x~iphone.png" width="640" height="960"/>
<splash src="resources/ios/splash/Default~iphone.png" width="320" height="480"/>
</platform>
<allow-navigation href="*"/>
<preference name="webviewbounce" value="false"/>
<preference name="UIWebViewBounce" value="false"/>
<preference name="DisallowOverscroll" value="true"/>
<preference name="android-minSdkVersion" value="16"/>
<preference name="BackupWebStorage" value="none"/>
<preference name="SplashMaintainAspectRatio" value="true"/>
<preference name="FadeSplashScreenDuration" value="300"/>
<preference name="loadUrlTimeoutValue" value="700000"/>
<preference name="orientation" value="portrait"/>
<preference name="SplashScreen" value="screen"/>
<preference name="SplashScreenDelay" value="3000"/>
<feature name="StatusBar">
<param name="ios-package" onload="true" value="CDVStatusBar"/>
</feature>
<plugin name="ionic-plugin-keyboard" spec="~2.2.1"/>
<plugin name="cordova-plugin-whitelist" spec="1.3.1"/>
<plugin name="cordova-plugin-console" spec="1.0.5"/>
<plugin name="cordova-plugin-statusbar" spec="2.2.1"/>
<plugin name="cordova-plugin-device" spec="1.1.4"/>
<plugin name="cordova-plugin-splashscreen" spec="~4.0.1"/>
<plugin name="cordova-plugin-facebook4" spec="~1.7.4">
<variable name="APP_ID" value="XXXXXXXXXX"/>
<variable name="APP_NAME" value="theWhoZoo"/>
</plugin>
<plugin name="cordova-plugin-googleplus" spec="~5.1.1">
<variable name="REVERSED_CLIENT_ID" value="com.googleusercontent.apps.XXXXXXXXXXXXXXXXXXX"/>
</plugin>
<plugin name="cordova-plugin-crop" spec="~0.3.1"/>
<plugin name="cordova-plugin-app-version" spec="~0.1.9"/>
</widget>
I then run:
ionic cordova build android
to build an apk
file. When I install this apk
on my Android device, the icon and splash screen is still the same default Cordova image:
If anyone can help, I would appreciate it.
More info:
global packages:
@ionic/cli-utils : 1.3.0
Cordova CLI : 6.4.0
Ionic CLI : 3.3.0
local packages:
@ionic/app-scripts : 1.3.0
@ionic/cli-plugin-cordova : 1.3.0
@ionic/cli-plugin-ionic-angular : 1.3.0
Cordova Platforms : android 6.0.0 ios 4.3.1
Ionic Framework : ionic-angular 3.2.1
System:
Node : v7.10.0
OS : macOS Sierra
Xcode : Xcode 8.3.2 Build version 8E2002
ios-deploy : not installed
ios-sim : not installed
We are seeing this same behavior, when built locally the apk can be opened and one can see the plug is listed in the cordova_plugins.js file however when the build ionic package build, when the apk is downloaded and checked for the entry in cordova_plugins.js it is not present.
As you have suggested I have rolled the spec back to 1.8.4, executed the ionic package build, downloaded the apk and confirmed that now the plugin is once again present.
Are you sure that you are on android ? Just kidding...
Hum... what about the icon/splash.png outside the folder android/ios/... ?
Path :
YourProject/resources/icon.png
YourProject/resources/splash.png
Let me know. I had the same problem but in my case, it was the config.xml, there is mine (just with the ionic resources command line (CLI)
There is only all the lines that concern the SplashScreen.
config.xml :
<preference name="SplashMaintainAspectRatio" value="true" />
<preference name="FadeSplashScreenDuration" value="300" />
<preference name="SplashShowOnlyFirstTime" value="false" />
<preference name="SplashScreen" value="screen" />
<preference name="SplashScreenDelay" value="3000" />
<preference name="loadUrlTimeoutValue" value="700000" />
<platform name="android">
<allow-intent href="market:*" />
<icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
<icon density="mdpi" src="resources/android/icon/drawable-mdpi-icon.png" />
<icon density="hdpi" src="resources/android/icon/drawable-hdpi-icon.png" />
<icon density="xhdpi" src="resources/android/icon/drawable-xhdpi-icon.png" />
<icon density="xxhdpi" src="resources/android/icon/drawable-xxhdpi-icon.png" />
<icon density="xxxhdpi" src="resources/android/icon/drawable-xxxhdpi-icon.png" />
<splash density="land-ldpi" src="resources/android/splash/drawable-land-ldpi-screen.png" />
<splash density="land-mdpi" src="resources/android/splash/drawable-land-mdpi-screen.png" />
<splash density="land-hdpi" src="resources/android/splash/drawable-land-hdpi-screen.png" />
<splash density="land-xhdpi" src="resources/android/splash/drawable-land-xhdpi-screen.png" />
<splash density="land-xxhdpi" src="resources/android/splash/drawable-land-xxhdpi-screen.png" />
<splash density="land-xxxhdpi" src="resources/android/splash/drawable-land-xxxhdpi-screen.png" />
<splash density="port-ldpi" src="resources/android/splash/drawable-port-ldpi-screen.png" />
<splash density="port-mdpi" src="resources/android/splash/drawable-port-mdpi-screen.png" />
<splash density="port-hdpi" src="resources/android/splash/drawable-port-hdpi-screen.png" />
<splash density="port-xhdpi" src="resources/android/splash/drawable-port-xhdpi-screen.png" />
<splash density="port-xxhdpi" src="resources/android/splash/drawable-port-xxhdpi-screen.png" />
<splash density="port-xxxhdpi" src="resources/android/splash/drawable-port-xxxhdpi-screen.png" />
</platform>
<platform name="ios">
<allow-intent href="itms:*" />
<allow-intent href="itms-apps:*" />
<icon height="57" src="resources/ios/icon/icon.png" width="57" />
<icon height="114" src="resources/ios/icon/icon@2x.png" width="114" />
<icon height="40" src="resources/ios/icon/icon-40.png" width="40" />
<icon height="80" src="resources/ios/icon/icon-40@2x.png" width="80" />
<icon height="120" src="resources/ios/icon/icon-40@3x.png" width="120" />
<icon height="50" src="resources/ios/icon/icon-50.png" width="50" />
<icon height="100" src="resources/ios/icon/icon-50@2x.png" width="100" />
<icon height="60" src="resources/ios/icon/icon-60.png" width="60" />
<icon height="120" src="resources/ios/icon/icon-60@2x.png" width="120" />
<icon height="180" src="resources/ios/icon/icon-60@3x.png" width="180" />
<icon height="72" src="resources/ios/icon/icon-72.png" width="72" />
<icon height="144" src="resources/ios/icon/icon-72@2x.png" width="144" />
<icon height="76" src="resources/ios/icon/icon-76.png" width="76" />
<icon height="152" src="resources/ios/icon/icon-76@2x.png" width="152" />
<icon height="167" src="resources/ios/icon/icon-83.5@2x.png" width="167" />
<icon height="29" src="resources/ios/icon/icon-small.png" width="29" />
<icon height="58" src="resources/ios/icon/icon-small@2x.png" width="58" />
<icon height="87" src="resources/ios/icon/icon-small@3x.png" width="87" />
<splash height="1136" src="resources/ios/splash/Default-568h@2x~iphone.png" width="640" />
<splash height="1334" src="resources/ios/splash/Default-667h.png" width="750" />
<splash height="2208" src="resources/ios/splash/Default-736h.png" width="1242" />
<splash height="1242" src="resources/ios/splash/Default-Landscape-736h.png" width="2208" />
<splash height="1536" src="resources/ios/splash/Default-Landscape@2x~ipad.png" width="2048" />
<splash height="2048" src="resources/ios/splash/Default-Landscape@~ipadpro.png" width="2732" />
<splash height="768" src="resources/ios/splash/Default-Landscape~ipad.png" width="1024" />
<splash height="2048" src="resources/ios/splash/Default-Portrait@2x~ipad.png" width="1536" />
<splash height="2732" src="resources/ios/splash/Default-Portrait@~ipadpro.png" width="2048" />
<splash height="1024" src="resources/ios/splash/Default-Portrait~ipad.png" width="768" />
<splash height="960" src="resources/ios/splash/Default@2x~iphone.png" width="640" />
<splash height="480" src="resources/ios/splash/Default~iphone.png" width="320" />
</platform>
<plugin name="cordova-plugin-splashscreen" spec="^4.0.3" />
Thanks, that's bundle size is just ionic build browser --prod
, then the server is set to serve static content gzipped.
The app source is here: https://github.com/openchargemap/ocm-labs/tree/master/App/Ionic2/ocm-app
However it's quite specialised and is doing a lot of stuff you wouldn't strictly need (like multiple map providers).
Reading here, it looks like there's a bug in the 6.0.0 version of the Android Cordova platform. So it looks like an upgrade fixes it.
ionic cordova platform rm android
ionic cordova platform add android@latest
ionic cordova resources
ionic cordova build android
However, when I upgraded to android 6.2.3
(latest), I now get:
ionic cordova build android
> cordova build android
✖ Running command - failed!
[ERROR] Cordova encountered an error.
You may get more insight by running the Cordova command above directly.
[ERROR] An error occurred while running cordova build android (exit code 1):
Error: cordovaProject.projectConfig.getFileResources is not a function
Richards-MacBook-Pro:theWhoZoo richardmarais$ (node:60728) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: channel closed
(node:60728) DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
I am going to try figure this out first, then hopefully the above issue will be resolved.
@ShehramTahir Thank you very much
A friend of mine has been working on a project in ionic and has sent me a zip folder with some files like "bower.json" "gulpfile.js" a few other things and some folders and something called "ionic.project". I have no idea what ionic is or how it works and I don't know how to open any of the files.
I am very comfortable working in Xcode and just want to open it there. How do I convert it all to Xcode? I never use terminal and a lot of these forums tell me to do things that I'm very unsure about. Please can anyone help me?
I upgraded Codova, and now I can build an apk:
npm install -g cordova@latest
. (Cordova CLI : 7.0.1 )
cordova build android
Now the icon is there!!! The Splash screen is just white though.
Hi Ionic lovers and ionic team, For very interesting project (Dating platform) i am looking best options and solutions.
I have a dating platform project and i am thinking about ionic framework, can i use on this project, is this good idea, is ionic enough strong etc. i have a few questions for ionic experts and experienced developers.
Few points for more idea; - Huge using (150.000+ active users and 25.000+ db transactions) - With Asp.Net Web services / Json / Javascript - Lot of Facebook and Google integrations for users profile and locations - With MSSQL db. - Just Using GPS hardware for locations (nearby option)
Is Ionic good idea for this project ? if yes Is Ionic enough strong framework for this type projects ?
if not What is your advice ?
Thank you everybody..
Verify your icon.png and splash.png in yourproject/resources
then do in the CLI (on macbook) :
sudo ionic resources
To be sure that everything has been applied
Hello,
Someone has any suggestion about catching and logging javascript error in real device ? The logs that we found in xcode or android sutdio are about native errors. I saw some libs like atatus, rollbar ... which are not free.
Does ionic have tools for this subject ?
Hey everyone,
I've noticed this issue with my Ionic build. When I run ionic cordova build ios --prod, I get the following errors:
Running app-scripts build: --prod --iscordovaserve --externalIpRequired --nobrowser
[18:02:10] build prod started ...
[18:02:10] clean started ...
[18:02:10] clean finished in 5 ms
[18:02:10] copy started ...
[18:02:10] ngc started ...
[18:02:12] build prod failed: Error encountered resolving symbol values statically. Calling function 'makeDecorator',
function calls are not supported. Consider replacing the function or lambda with a reference to an exported
function, resolving symbol Injectable in
/Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/di/metadata.d.ts,
resolving symbol Injectable in
/Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/di.d.ts,
resolving symbol Injectable in
/Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/core.d.ts,
resolving symbol Injectable in
/Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/index.d.ts,
resolving symbol AngularFireAuth in
/Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/auth/auth.d.ts, resolving symbol
AngularFireAuth in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/auth/auth.d.ts
[WARN] Error occurred during command execution from a CLI plugin (@ionic/cli-plugin-cordova). Your plugins may be out of date.
Error: Error encountered resolving symbol values statically. Calling function 'makeDecorator', function calls are not supported. Consider replacing the function or lambda with a reference to an exported function, resolving symbol Injectable in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/di/metadata.d.ts, resolving symbol Injectable in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/di.d.ts, resolving symbol Injectable in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/src/core.d.ts, resolving symbol Injectable in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/node_modules/@angular/core/index.d.ts, resolving symbol AngularFireAuth in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/auth/auth.d.ts, resolving symbol AngularFireAuth in /Applications/MAMP/htdocs/bandly-app-mobile/node_modules/angularfire2/auth/auth.d.ts
When I run ionic cordova build ios
, I don't get the errors, only when I add the --prod
flag.
Here is my package.json file:
dependencies": {
"@angular/common": "4.0.2",
"@angular/compiler": "4.0.2",
"@angular/compiler-cli": "4.0.2",
"@angular/core": "4.0.2",
"@angular/forms": "4.0.2",
"@angular/http": "4.0.2",
"@angular/platform-browser": "4.0.2",
"@angular/platform-browser-dynamic": "4.0.2",
"@ionic-native/camera": "^3.8.0",
"@ionic-native/core": "3.6.1",
"@ionic-native/facebook": "^3.8.0",
"@ionic-native/file": "^3.6.1",
"@ionic-native/geolocation": "^3.8.0",
"@ionic-native/in-app-browser": "^3.8.0",
"@ionic-native/keyboard": "^3.8.0",
"@ionic-native/splash-screen": "^3.6.1",
"@ionic-native/status-bar": "3.6.1",
"@ionic-native/transfer": "^3.8.0",
"@ionic/cli-plugin-cordova": "^1.3.0",
"@ionic/storage": "2.0.1",
"@types/algoliasearch": "^3.18.0",
"@types/jasmine": "^2.5.41",
"@types/lodash": "^4.14.55",
"@types/lodash.update": "^4.10.1",
"algoliasearch": "^3.21.1",
"angular2-autosize": "^1.0.1",
"angular2-moment": "^1.0.0",
"angularfire2": "^2.0.0-beta.7-pre",
"cordova-android": "6.1.0",
"cordova-ios": "^4.4.0",
"cordova-plugin-admobpro": "^2.28.3",
"cordova-plugin-camera": "^2.4.1",
"cordova-plugin-compat": "^1.1.0",
"cordova-plugin-console": "^1.0.7",
"cordova-plugin-crosswalk-webview": "^2.3.0",
"cordova-plugin-device": "^1.1.6",
"cordova-plugin-email": "^1.2.6",
"cordova-plugin-extension": "^1.5.1",
"cordova-plugin-facebook4": "^1.9.0",
"cordova-plugin-file": "^4.3.3",
"cordova-plugin-file-transfer": "^1.6.3",
"cordova-plugin-geolocation": "^2.4.3",
"cordova-plugin-inappbrowser": "^1.7.1",
"cordova-plugin-splashscreen": "^4.0.3",
"cordova-plugin-statusbar": "^2.2.3",
"cordova-plugin-whitelist": "^1.3.2",
"cordova-plugin-wkwebview-engine": "git+https://github.com/driftyco/cordova-plugin-wkwebview-engine.git",
"firebase": "^3.7.2",
"imgcache.js": "^1.1.1",
"ionic-angular": "3.1.1",
"ionic-plugin-keyboard": "^2.2.1",
"ionicons": "3.0.0",
"lodash": "^4.17.2",
"moment": "^2.17.1",
"ng-semantic": "^1.1.13",
"ng2-toasty": "^4.0.0",
"prod": "^1.0.1",
"rxjs": "5.1.1",
"sw-toolbox": "3.4.0",
"zone.js": "^0.8.10"
},
"devDependencies": {
"@angular/cli": "^1.0.4",
"@ionic/app-scripts": "1.1.4",
"@ionic/cli-plugin-cordova": "1.1.1",
"@ionic/cli-plugin-ionic-angular": "1.3.0",
"@ionic/cli-plugin-ionic1": "1.3.0",
"typescript": "~2.2.1"
},
And when I run ionic info
:
[ERROR] Error with /Applications/MAMP/htdocs/bandly-app-mobile/www/lib/ionic/version.json file: FILE_NOT_FOUND
global packages:
@ionic/cli-plugin-proxy : 1.3.0
@ionic/cli-utils : 1.3.0
Cordova CLI : 7.0.0
Ionic CLI : 3.3.0
local packages:
@ionic/app-scripts : 1.1.4
@ionic/cli-plugin-cordova : 1.3.0
@ionic/cli-plugin-ionic-angular : 1.3.0
@ionic/cli-plugin-ionic1 : 1.3.0
Cordova Platforms : ios 4.4.0
Ionic Framework : ionic-angular 3.1.1
Ionic Framework : unknown
System:
Node : v6.9.0
OS : OS X El Capitan
Xcode : Xcode 8.2.1 Build version 8C1002
ios-deploy : 1.9.1
ios-sim : 5.0.13
Could this be an issue with typings? Anyway, if anyone has run into this issue as well, let me know! Thanks in advance!
ionic build android, does not respect the version set on config.xml<widget android-versionCode="8"
It uses the version set at:Android Studio > Project Structure > Flavors > Version Code
everytime I need to publish a new apk I have to first open Android Studio, change version code, save and then go back to ionic build...
any thoughts on how to fix this?
if the architecture is designed well enough, why not? only one way to find out.
are you using MSSQL because of Asp.Net? I think a NoSQL db could be quicker if you're smart with the design.
right now though there are some issues with virtual scroll which if you have big lists could be problematic. but there are lots of different ways to get around this. good luck!
We are using sentry and are very happy with that!.
I found this tutorial very helpful:
(Ionic Native will definitely be your friend)
Actually problem here around User experience (Feeling) because we talking about 150.000 user in first phase and 15.000 - 20.000+ db transactions.
Ionic Native sound good we ll think about that but i want to know your ideas about Db why NoSQL ?
That answer went above and beyond. Much appreciated sir