Giter Site home page Giter Site logo

Comments (10)

mak12 avatar mak12 commented on May 20, 2024 3

I used this one
https://github.com/Richou/react-native-android-location-enabler#readme

from react-native-location-enabler.

aataa-fa avatar aataa-fa commented on May 20, 2024 3

You can use the platform-specific code of react-native.
import the package when the phone is only android. first create two files by the name locationEnabler.android.js and locationEnabler.ios.js
import the package in locationEnabler.android.js and use it as usual.

from react-native-location-enabler.

aataa-fa avatar aataa-fa commented on May 20, 2024 3

the link for platform-specific code of react-native
https://reactnative.dev/docs/platform-specific-code.html#platform-specific-extensions

from react-native-location-enabler.

mak12 avatar mak12 commented on May 20, 2024 2

No, I ended up changing the library.

from react-native-location-enabler.

kadirmenz avatar kadirmenz commented on May 20, 2024

Hi did you fix it? I face with same problem

from react-native-location-enabler.

kadirmenz avatar kadirmenz commented on May 20, 2024

Can you give me advice for this future?

from react-native-location-enabler.

sameerasad avatar sameerasad commented on May 20, 2024

is there any way to edit the alert content?

from react-native-location-enabler.

aataa-fa avatar aataa-fa commented on May 20, 2024

is there any way to edit the alert content?

there is not any way to change the alert content, cause it comes from native android settings api

from react-native-location-enabler.

KienHaVan avatar KienHaVan commented on May 20, 2024

`import {Platform} from 'react-native';

import AddingDevicesScreenAndroid from './AddingDevicesScreen.android';
import AddingDevicesScreenIos from './AddingDevicesScreen.ios';

export default Platform.select({
ios: AddingDevicesScreenIos,
android: AddingDevicesScreenAndroid,
});`

You guys can try this. This work for me. I made 2 versions for each specific platform.

from react-native-location-enabler.

amir-ibrahim avatar amir-ibrahim commented on May 20, 2024

the best solution for me:
https://reactnative.dev/docs/platform-specific-code#platform-specific-extensions

from react-native-location-enabler.

Related Issues (17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.