react-native-ble-nitro
Version:
High-performance React Native BLE library built on Nitro Modules - drop-in replacement for react-native-ble-plx
30 lines (29 loc) • 758 B
JavaScript
import withBleNitro, { withBleNitroAndroid, withBleNitroIOS } from './withBleNitro';
/**
* Expo Config Plugin for react-native-ble-nitro
*
* Configures iOS and Android permissions and settings for BLE operations
*
* @example
* ```json
* {
* "expo": {
* "plugins": [
* [
* "react-native-ble-nitro",
* {
* "isBackgroundEnabled": true,
* "modes": ["peripheral", "central"],
* "bluetoothAlwaysPermission": "Allow $(PRODUCT_NAME) to connect to bluetooth devices"
* }
* ]
* ]
* }
* }
* ```
*/
const plugin = (config, props) => {
return withBleNitro(config, props || {});
};
export default plugin;
export { withBleNitro, withBleNitroAndroid, withBleNitroIOS };