I swear I have thoroughly searched.
Ionic, (btw, only Capacitor works for ios, and only Cordova for android, -just cordova, or just capacitor won't work for both-, and... some cordova is still needed for ios-capacitor to work, but I was able to make all work nice, and publish in both stores, and working on both devices, though issues may happen depending on the plugins you need... feel free to comment).
Then I added chart.js, and in Android, it´s all ok on device, but when testing on an ios device, charts are blank.
No chart.js code sample needed here, as the code is just the same you can find in a simple google search, it may as well just be copy-paste and works fine as just mentioned.
As close as I've come is to figure it may have something to do with the canvas tag, I simply use
<canvas #someCanvas></canvas>
but it may be needed to add some other properties to this tag, for it to work on ios device.
Any help/thoughts, please? Thanks :)
Chart.js dropped support for older browsers so you might have to pollyfill the resize observer and maby some features.
Source: https://github.com/chartjs/Chart.js/issues/8414
Related
Even though Clickable Span is not supported in {N}, but is there any workaround for this?
I have read the following thread but still don't really know how to implement on NativeScript-Vue, may anyone help, please?
Feature request: ClickableSpan support for iOS and Android
Nothing changes with Vue except the fact everything will be JS and event handlers will follow Vue syntax.
Here is the Vue implementation of the same demo project. I was able to test it on Android, not having access to iOS device ATM. Let me know in case if you hit any issues.
Update:
Updated playground link with fixes for iOS
I´ve set up a clone of this repo, and got it up and running at heroku:
https://github.com/dondido/webrtc-video-room
.. after trying about 15 others that I had various problems with. It works great under Windows in chrome and firefox, but when trying to access it with a webview on android in the app I´m developing (in B4A), I see only a grey screen. I do however manage to succesfully use https://appr.tc which is a very similar demo from google in the webview, so something should be amended in the android code. I think it relates to navigator.mediaDevices.getUserMedia, but I really don´t know what needs to be changed for this to function. I´ve been sitting and comparing the git repo for mentioned appr.tc but can´t nail the part that I have to amend. I am aware that I can just clone the appr.tc repo instead, but this one also needs GAE, which I want to avoid.
Any help?
Thanks!
We are using Cordova 5.0.0 and its cordova-camera-plugin
When we are testing it on Android, the app crashes when the user takes a photo.
Looking at the links below, it seems that our app is being killed while the camera app it on front.
PhoneGap camera restarts the application
https://github.com/shaithana/cordova-plugin-wezka-nativecamera
While there are some answers but it seems to be outdated: The foreground camera plugin is not suitable to newer devices or Cordova and other solutions didn't work for us
Does anyone have an up-to-date solution?
Try to use this forked cordova-android and cordova-plugin-camera.
The docs, sample and discussion on the approach used can be found in the cordova-android PR.
BTW, the PRs are going to be merged soon.
First question that comes to my mind is: Why using this camera plugin: https://github.com/shaithana/cordova-plugin-wezka-nativecamera
It's obviously a fork. You might have a good reason for that. It's also outdated. Last contribution was one year ago.
Maybe you want to give the "official" plugin a shot:
https://github.com/apache/cordova-plugin-camera
Going deeper into detail without knowing more about your testing environment (which device(s) with which Android version) and without having possibility to review entire related code, is not possible and answers may not give any reliable advice for change.
Have you ensured, that the call to the camera plugin cannot happen before "deviceready" was triggered? Is cordova.js loaded?
Update:
You may also want to switch from raw alerts to console output. I recognized several times that alerts in callbacks triggered from plugins could cause some trouble.
As a general rule of thumb: Use console.log() instead of alert() and connect with Chrome (chrome://inspect) to the emulator or device to see what happens. You can additionally use adb logcat to have a look into the device log.
I am developing a Cordova 3.0.0 application which needs to periodically show notifications to the user. They need to be the kind of notifications that live in the notification center on iOS; modal popups aren't good enough as the app may be running in the background at the time.
The built-in Notification plugin only provides modal popups: http://docs.phonegap.com/en/3.0.0/cordova_notification_notification.md.html
I have seen 3rd party plugins, such as this: https://github.com/DrewDahlman/Phonegap-LocalNotification
- however, they are developed for much older versions of Cordova/PhoneGap.
Is it possible to use any of these with Cordova 3; or is there a better way to do it (device-independently if at all possible, as I need to have similar behaviour on Android as well as iOS); or would my best option be to downgrade to an older version of Cordova?
Thanks
Drew Dalhman's Plugin still has some Issues. For example cancel() and background callback do not work.
This one, from Sebastián Katzer is updated and works with Cordova 3+ :
https://github.com/katzer/cordova-plugin-local-notifications
for iOS, Android and WP8
According to the issues for Drew Dalhman's plugin some people have had some success using that plugin in Cordova 3.0.6:
https://github.com/DrewDahlman/Phonegap-LocalNotification/issues/18
Rather than downgrading to an earlier version I'd look to see if a pull request can be created for the plugin. This will help everyone and will allow you to take advantage of Cordova improvements.
I was actually researching this same issue earlier for Android. Not implemented anything yet, but this tutorial seems to have some useful information (Part 3 is most relevant to showing notifications):
http://red-folder.blogspot.co.uk/2012/09/phonegap-service-tutorial-part-1.html
I googled but couldn't find anything.
My suggestion would be that you write your own plugins/extensions for Android and IOS respectively. It isn't difficult. The problem with writing your own IOS plugin is that you need to have a mac and iphone/ipad. Also, try the Phonegap-LocalNotification plugin you mention, it could possibly work.
Im starting to loose my mind her.
Im building a VERY simple app.
All it needs to do, is show some information, an play some videos.
Everything works just great on iOS. I simply link to the video like this <span></span><img src="img/vidImg_afbryder.png" />, and it starts playing.
But on Android, its a totally deferent story. When i straigt-up link to the video like the ios version, nothing happens.
When i use this https://github.com/macdonst/VideoPlayer, and my link looks like this
<span></span><img src="img/vidImg_afbryder.png" />, nothing happens.
All the videos ar contained locally in the app, as it needs to work offline.
Im building the app with HTML/CSS/JS in webstorm and then compiling it on build.phonegap.com/
Im not using x-code or anythin, just stright-up HTML/CSS/JS. i do have the config.xml file
Ive tried searching like a mad man, but still no luck. Can someone help me, or point me in the right direction.
P.S. This is my first app, and therefor my first encounter with phonegap.
If you use any one plugin, you have to use a specific one for Android and one for iOS. After this, you need to compile using xcode or eclipse, for example. To use the plugin you mentioned, have a look on http://www.adobe.com/devnet/html5/articles/getting-started-with-phonegap-in-eclipse-for-android.html