Is there a way to make a browser aware of iBeacon devices in its proximity?
Similar to the way HTML5 Geolocation is working...
If not would this be something that can be achieved with a browser plug-in that can provide the detail to be consumed by javascript?
Unfortunately, no. No web browsers have implemented any bridges between beacon detection and JavaScript.
I don't think a plugin approach is possible on mobile browsers (either iOS or Android), because neither browser supports asynchronous communication between external apps and JavaScript in Mobile Safari / Mobile Chrome. The best you could do is have a custom app that responds to a beacon, then launches a web page in the browser. But I realize that isn't what you are asking for.
If you want to build a native app with JavaScript, you can use Cordova (aka PhoneGap) and use plugins that provide beacon support. My company has one for our ProximityKit beacon framework:
https://github.com/RadiusNetworks/proximitykit-plugin-cordova
There is also a Cordova plugin that has basic beacon support here:
https://github.com/petermetz/cordova-plugin-ibeacon
This looks promising (2016), Google Chrome developers site showing a desktop browser feature as a work in progress.
https://developers.google.com/web/updates/2015/07/interact-with-ble-devices-on-the-web?hl=en
Even though the Web Bluetooth API specification is not finalized yet,
the Chrome Team is actively looking for enthusiastic developers (I
mean you) to try out this work-in-progress API and give feedback on
the spec and feedback on the implementation.
Web Bluetooth API is currently available to be enabled experimentally
on your origin in Origin Trials, or locally on your machine using an
experimental flag. The implementation is partially complete and
currently available on Chrome OS, Chrome for Android M, Linux, and
Mac.
Go to chrome://flags/#enable-web-bluetooth, enable the highlighted
flag, restart Chrome and you should be able to scan for and connect to
nearby Bluetooth devices, read/write Bluetooth characteristics,
receive GATT Notifications and know when a Bluetooth device gets
disconnected.
https://github.com/WebBluetoothCG/web-bluetooth/blob/gh-pages/implementation-status.md
There's a W3C specification for this Web Bluetooth, but there's no support yet: http://caniuse.com/#search=bluetooth.
If you decide to write a Phonegap plugin implementing this spec will be a good starting point.
Related
Some browsers (mobile Mi Browser, for instance) don't support WebRTC - they have no RTCPeerConnection API. So the users of your WebRTC web app have to open it in another one.
Is there a way to make your WebRTC app work without an explicit browser-change action from the user, especially on a mobile device?
I tried to investigate the following:
Deep Link. Looks like we can't redirect the user to another browser using deep link (I haven't found Chrome deep link for mobile).
Send WebRTC sources to browser / use third-party WebRTC lib. This won't work either, you need WebRTC support in the browser source code.
WebRTC is a framework based on a set of standards. It includes not only capability to get information about user input/output devices, but also set of network protocols which based on UDP (from getting client's IP to transfer arbitrary data through data channel using SCTP protocol). So, as you already may guess, it's impossible to support in a browser which doesn't have it, this is why point (2) will not work.
In case of point (1 - Open Chrome). On iOS exists custom protocol to open URL in chrome "googlechromes://stackoverflow.com", but it's better to explicitly say user that current browser doesn't support required functionality; And provide links on list of popular browsers for download (Chrome, Firefox, etc.); And already on these websites user will be redirected to the proper store for downloading native app.
I am looking for a way to send and display notifications on ios pwa apps.
I know it is not possible since the ios safari (and non of the other browsers on ios) support neither the push api nor the notification api.
I am wondering if there was a workaround to do that.
I have already taken a look at this answer, but honestly didn't understand at all.
The truth is NOT for mobile Safari, at the time I write this answer. I am doing a long research... The Apple PWA on Safari increased a lot, but is not comparable to others like Google Chrome browser. As It was said in the article:
At this point in time Apple's iPhone and iPads do not support native
push notifications. You can gracefully fallback to SMS notifications.
So, till the moment I have this resume to share:
Do Progressive Web Apps (PWA) work on iOS? YES...
Apple may wants to turn the PWA as an alternative to the Apple Store.
We still can’t open an external link in Safari
Still can’t use Push Notifications
There is a 50MB service worker cache limit
Web apps that have not been used will have their cached assets purged after 7 days
Fonts:webkit.org,developer.apple.com,brainhub.eu,love2dev.com,firt.dev
NEW:
Push API is currently in development for Safari (including iOS). It is not currently finished but should be available for testing in a Safari Technology Preview within the next few months.
OLD:
It is not possible to have Push Notifications on Safari. It's been brought up many times and has even been a topic of this years WWDC.
See the following threads:
https://developer.apple.com/forums/thread/681575
https://developer.apple.com/forums/thread/681748
If developers want push notifications in Safari we'll need to have a much louder voice. As stated in the link above, native apps got notifications in 2009, it's 2021 and Apple has not even indicated if they are willing to work on it.
I need to implement NFC (near field communication) in a PWA (progressive webapplication)
Every browser I have tested (Chrome MacOSX, Safari MacOSX, Safari iOS, Chrome for android) does not include the navigator.nfc object in navigator and it seems impossible to make use of this API: https://w3c.github.io/web-nfc/#conformance.
Is it possible to use NFC in any way in a PWA? Or do I have to develop a native application for this functionality?
Web NFC API is available only in Chrome for Android and that too when a flag is enabled(try about:flags) enabled.
Unless you are targeting your app for some internal corporate app where you can set the flag in all targeted users browser, I would recommend go with native code or wrapper(cordova or have a native app send in the details via web sockets)
This API is not making much progress since 2015 and so you can expect no magic to happen anytime soon. So don't rely on this API if you are targeting this for a critical app, especially when you cant control the end users browser settings.
From chrome 81 you can use NFC
https://blog.chromium.org/2020/02/chrome-81-near-field-communications.html
For example, I have a web site with authentication. Is there any fingerprint API, that can be used from JavaScript, to login users? Mobile OSs like Android and iOS has such API. So at least mobile version of browsers, in theory, can provide such functionality. But I can't find any information on the web about it.
Chrome 70 Beta, announced September 13, 2018, introduced web authentication.
Also enabled by default are macOS's TouchID and Android's fingerprint sensor via Web Authentication. These allow developers to access biometric authenticators through the Credential Management API's PublicKeyCredential type.
It is something that is being looked into. Currently, there is basic support in firefox and chrome: https://developer.mozilla.org/en-US/docs/Web/API/Web_Authentication_API
The main reason I'd like to use j2me is that one of its main advantages is that it can access the phone's resources through its various APIs. However, due to newer phones having web browsers like Safari, Opera, and Windows IE, it would be advantageous to build a web application so a user wouldn't have to download some software onto their phone. Is there a way I could build a web application that can also acquire resource information about the phone? Or maybe have j2me converted to Javascript (if that's even possible)?
You can make a link that would send an SMS, but other than that, there's no cross-platform api for accessing phone internals from browser, as far as I know.
So, if you've got to access phone's resources, you'll have to write a real app.
The webkit engine on recent Series60 phones has been given access to at least some phone resources.
Nokai calls it Web Runtime or WRT.
http://www.forum.nokia.com/Resources_and_Information/Documentation/