React Native "RNCSafeAreaView" was not found in the UIManager - android

I am running a react-native application on Mac. but I am getting "RNCSafeAreaView" was not found in the UIManager.

update version of this module by typing following command in terminal:
npm install react-native-safe-area-context#1.0.2
it will solve this problem

Related

I want to link a library in react native version 0.70.1 but I got a error error: unknown command 'link'

I want to link a library in react native version 0.70.1 but I got a error error: unknown command 'link' after trying this command react-native link react-native-notification-sounds
Linking is automatic since React Native 0.60. So no need to run react-native link.
After installing the library -
on android, just rebuild the app
npm run android
on ios, install the pod before rebuilding the app
npx pod-install ios
npm run ios

React-Native app throws SHA-1 error on build

This is now a problem I've been dealing with for a long long time and it has become an annoyance, so I would appreciate any kind of help.
I have been working on a react-native project with my team and everything was fine until I decided to relocate the project on my Mac and clone the repo from GitHub to my new location (I am not able to share the repo since it's private). Since then, when I run the npm run android / ios I run into the following error:
Screenshot of the error screen
I am able to start the app on the emulator by running npx react-native start and opening the app even after getting the error, so as I understand, it builds the app but fails to start it. However this means whenever I need a new build, I need to run a command, receive an error, run another command and open the app manually. Also, I am not able to create a build for my real iOS device at all.
I have tried deleting and reinstalling packages, clearing cache from watchman, react-native and metro bundler, reinstalling react-native-cli with --force, basically I have tried every solution I could find on StackOverflow related to my problem. Here are some solutions I found:
React-Native Bundle Error error SHA-1 for file is not computed
react native bundle sha-1 for file not computed(unable to load script from assets index.android.bundle)
How to remove error: bundling failed: ReferenceError: SHA-1 for file is not computed
react-native metro bundler error: bundling failed: ReferenceError: SHA-1 for file
Sadly, none of these worked for me. How can I solve this problem?
System:
macOS 11.1
Binaries:
Node: 14.15.3
npm: 6.14.9
Watchman: 4.9.0
npmPackages:
#react-native-community/cli: Not Found
react: 16.11.0
react-native: 0.62.2
Thanks in advance.
Issue should fixed by installing react-native-cli:
yarn global remove react-native
yarn global add react-native-cli
Credits source

I am getting this error while running react-native app in android studio

Here i shared the error.
Caused by: java.lang.Exception: Command config unrecognized. Make sure that you have run npm install and that you are inside a react-native project.
You can temporarily bypass the issue by forcing the #react-native-community/cli-platform-android to use the older version 3.0.2.
npm install --save #react-native-community/cli-platform-android#3.0.2
OR
yarn add #react-native-community/cli-platform-android#3.0.2

react-native run-android issue - error Android project not found

I create a react native app in C9. Now, I want to develop this app on my local machine with android settings. I downloaded the project.
cd myProjectFolder
react-native start
npm install
react-native run-android
Also, I add a project name in package.json.
The error is below:
error Android project not found. Are you sure this is a React Native project?
If android project/folder does not exit in your root project then run :
react-native eject
I encountered this issue after I ruan ./gradlew clean. Tried serval methods but vain. Then I ran ./gradlew in the Android directory. It worked for me.
// Android
./gradlew

Ionic - Error: Cannot find module 'android-versions'

When a try to run
ionic run android --device
I'm getting an error of module:
Error: Cannot find module 'android-versions'
Versions:
java -version
java version "1.8.0_144"
Android studio Version 2.3.3
ionic -v
2.2.1
cordova -v
6.5.0
I found the problem and expect help somebody.
I just run
npm install android-versions --save
in the project folder and worked.
Not sure if this will help some other Ionic developers, but I was getting the same Error: Cannot find module 'android-versions' and I fixed it by removing and adding the Android platform again:
ionic cordova platform remove android --save
And then
ionic cordova platform add android --save
If anyone is having this issue while using yarn and even after adding android-versions... it seems that there are differences in yarn/npm files which break...
I ended up removing my node_modules folder, then installing it with npm instead of yarn. It worked!

Categories

Resources