Posts

Showing posts with the label cordova

How to setup cordova-plugin-firebase-authenication for ionic 3?

How to setup cordova-plugin-firebase-authenication for ionic 3? I am using this plugin : https://github.com/chemerisuk/cordova-plugin-firebase-authentication to use Phone verify for my ionic android application. but, when i install this plugin and try to run it using : ionic cordova run android ..It gives me following error: ionic cordova run android [string/google_app_id] /home/intel/blank/platforms/android/app/src/main/res/values/strings.xml [string/google_app_id] /home/intel/blank/platforms/android/app/build/generated/res/google-services/debug/values/values.xml: Error: Duplicate resources I checked my strings.xml and values.xml but there are not any duplicate api key or id. My project.properties file : target=android-26 android.library.reference.1=CordovaLib android.library.reference.2=app cordova.gradle.include.1=cordova-plugin-firebase/starter-build.gradle cordova.system.library.1=com.google.gms:google-services:+ ...

Cordova Media Play sequencial Audios with delay

Cordova Media Play sequencial Audios with delay Im trying to play 3 audio files sequencially, with 1 second delay. This code works well at Android Device(actual device, after build), but on iOs(via xcode run) and browser it wait 3 seconds(3000 milisecondes) and play all at once. What could be the solution for all platforms? function playAudio(files) { var arquivos = files.split('-') for (var i = 0, length = arquivos.length; i < length; i++) { var arquivo = 'media/notas/'+arquivos[i]+'.mp3' my_media = new Media(getMediaURL(arquivo),function () {},function (err) { window.alert("playAudio():Audio Error: " + err)}); my_media.play(); console.log(getMediaURL(arquivo)) wait(1000); } function wait(ms){ var start = new Date().getTime(); var end = start; while(end < start + ms) { end = new Date().getTime(); } } while(end < start + ms) { That's a lot of CPU usage, couldn't you use await instead...

Task.leftShift(Closure) method has been deprecated

Task.leftShift(Closure) method has been deprecated I am trying to run conference application using command ionic start conf conference It works fine when i run in my browsers as ionic serve But when i try to deploy using the command ionic cordova run android ANDROID_HOME=/Users/macbookpro/Library/Android/sdk JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_131.jdk/Contents/Home studio Subproject Path: CordovaLib Subproject Path: app publishNonDefault is deprecated and has no effect anymore. All variants are now published. null The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead. at build_br7zud05gv2qtk7uiqjkqvaey.run(/Users/macbookpro/ionic-conference-app/platforms/android/app/build.gradle:144) org.xwalk:xwalk_core_library:22+ Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead. My cordova version is 8.0.0 Ionic vers...