Questions tagged [react-native-device-info]

39 questions
11
votes
5 answers

How to get current country of Device in React Native (iOS and Android)?

I am trying to get current country of device in but didn't find anything. Is there something to do so in React Native? I tried using react-native-device-info but it is also not supporting but in previous version it can be get by getDeviceCountry().…
Shivam Tiwari
  • 550
  • 1
  • 7
  • 22
8
votes
6 answers

@React-native-community/react-native-device-info: NativeModule.RNDeviceInfo is null. To fix this issue these steps: *Run 'react-native link

I just created the app with "react-native init NameProject" and had a Base directory that I use constantly, so when I inserted it, I installed the dependencies and link, it happens to me ... I already deleted the "node_modules" directory,…
7
votes
1 answer

How to resolve React Native Firebase Error (messaging().getToken()), related to react-native-device-info

I am in the process of migrating react-native-device-info from v2 to v3 and I have a breaking change. Prior to updating the package, everything was working fine. The error appears on all emulators and real devices. The error I get is:…
5
votes
1 answer

React Native force component refresh when the app goes to foreground

My app displays some Texts. I need to re-render a Component when the font size changes via Settings --> Accessibility --> Font size: So basically this is se sequence: The app is opened (foreground). The user opens the Phone Settings so the app…
5
votes
1 answer

Manifest merger failed. After adding and linking react-native-device-info

Manifest merger failed : Attribute meta-data#android.support.VERSION@value value=(26.0.1) from [com.android.support:cardview-v7:25.3.1] AndroidManifest.xml:24:9-31 is also present at [com.android.support:support-v4:26.1.0]…
4
votes
1 answer

Can I get some sample output from react-native-device-info?

This repo (https://github.com/rebeccahughes/react-native-device-info#usage) looks like it has some methods for accessing device information through react native. Does anyone have some sample output data from actual devices? It would be nice to just…
cutmancometh
  • 1,677
  • 3
  • 20
  • 28
3
votes
2 answers

How to get device Id in expo react native app

I am implementing API to connect app with server. I have to use deviceId there. As mentioned in here we can use third party library 'react-native-device-info'. But when I am using it I am getting errors as attached screenshots. As per error it's…
3
votes
2 answers

React native android not compiling with react-native-device-info

I'm getting the following error when I try to build the project using $ react-native run-android. > Task :react-native-device-info:compileDebugJavaWithJavac…
user7307981
3
votes
0 answers

How can I get the device phone number using device info in react-native in case of "Dual SIM"

If the mobile has Dual SIM card How can I get the device phone number using device info in react-native? I have added READ_PHONE_STATE permission in XML file. And added run time permissions PermissionsAndroid.PERMISSIONS.READ_PHONE_STATE. but I am…
Pratap Penmetsa
  • 1,137
  • 17
  • 41
2
votes
0 answers

I am not able to get MacAddress in react-native Android11 , i am using react-native-device-info

i am working in react native android application. i am using react-native-device info to get macAddress. if I add Android 10/9 mobile device for testing(debugging) then i got the macAddress but when i connect Android 11 then i got nothing in…
ViShU
  • 300
  • 2
  • 10
2
votes
0 answers

Does anyone know how to get the IMEI number of device in React Native using EXPO?

How can I get Device IMEI number in React Native using EXPO? Previously I was using react-native-imei to get IMEI Numbers of device when the App was created using react-native. Now we are having another app which is created using EXPO - it will be…
Sameer Patkar
  • 101
  • 1
  • 9
2
votes
1 answer

How can I get list of apps, images and videos of my device in react native?

I want to get list of apps, images and videos from my device and show them into list, how can i do this using react native? Thank in advance!!
Dhaval
  • 868
  • 12
  • 22
2
votes
1 answer

react-native-device-info unique ID

Is it safe to use a react-native-device-info unique ID? From what I can understand it will always remain unique for both iOS and android no matter how many times the app will be uninstalled. If not kindly suggest what else we can use to uniquely…
devedv
  • 562
  • 2
  • 15
  • 45
2
votes
1 answer

How do I prevent react-native-device-info causing React ambiguity on my setup?

I'm running into a problem with installing react-native-device-info into an existing react-native project (created using create-react-native-app and then ejecting) I run: yarn add react-native-device-info yarn install react-native link…
deworde
  • 2,679
  • 5
  • 32
  • 60
2
votes
1 answer

Does getUniqueID() from react-native-device-info can ever change?

I have a few questions: 1.Does getUniqueID() from react-native-device-info library can ever change? Or it’s staying the same all the time If it can change what parameter that his unique for the device from react-native-device-info library can’t be…
Tal Shani
  • 660
  • 1
  • 9
  • 26
1
2 3