问题
I'm trying to make an hybrid app by which phone will act as beacon, which mean it should transmit both an iBeacon and an Eddystone. Is there any cordova plugin available if not can anyone please suggest how can I make one.
回答1:
This Cordova plugin supports detection on both iOS and Android:
https://github.com/petermetz/cordova-plugin-ibeacon
It only supports transmission on iOS, but the underlying native Android Beacon Library it uses supports transmission:
http://altbeacon.github.io/android-beacon-library/beacon-transmitter.html
It should be reasonably simple to add the missing Cordova bindings for Android so that platform works to transmission as well.
来源:https://stackoverflow.com/questions/44096759/phone-act-as-beacon