@armanatz/expo-hms-location
Version:
Expo config plugin to configure @hmscore/react-native-hms-location on prebuild
14 lines (13 loc) • 588 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.default = withLocationPermissions;
const config_plugins_1 = require("expo/config-plugins");
const { withPermissions } = config_plugins_1.AndroidConfig.Permissions;
function withLocationPermissions(config, isBackgroundLocationEnabled) {
return withPermissions(config, [
'android.permission.ACCESS_COARSE_LOCATION',
'android.permission.ACCESS_FINE_LOCATION',
isBackgroundLocationEnabled &&
'android.permission.ACCESS_BACKGROUND_LOCATION',
].filter(Boolean));
}