react-native-slider
react-native-slider copied to clipboard
requireNativeComponent: "RNCSlider" was not found in the UIManager
Describe the bug
On IOS
On a Expo managed app - I use the Expo Dev Client and do not have an ios or android directory
I get this error after installing @react-native-community/slider :
requireNativeComponent: "RNCSlider" was not found in the UIManager
To Reproduce Steps to reproduce the behavior: Install the mentioned package and run the app
Expected behavior Not having an error
Additional information:
- Type: Real device
- Device: iPhone XS
- OS: iOS 15
- Package version: 4.1.12 (4.2.0 marked as not compatible with Expo, and does not fix the problem)
- Expo version: 44
- Expo CLI version: 5.2.0
Additional context
Screenshots (if applicable)
+1 In android
System: OS: macOS 12.3 CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz Memory: 209.48 MB / 16.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 16.13.2 - /usr/local/bin/node Yarn: 1.22.17 - /usr/local/bin/yarn npm: 8.1.2 - /usr/local/bin/npm Watchman: 2022.01.10.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.2 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5 Android SDK: Not Found IDEs: Android Studio: 2020.3 AI-203.7717.56.2031.7935034 Xcode: 13.3/13E113 - /usr/bin/xcodebuild Languages: Java: 11.0.11 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 17.0.2 => 17.0.2 react-native: 0.67.4 => 0.67.4 "@react-native-community/slider": "4.2.2", react-native-macos: Not Found npmGlobalPackages: react-native: Not Found
@rahulnainwal107 Do you also experience this problem on Expo?
@BartoszKlonowski, No not in Expo but in android.
@rahulnainwal107 If you experience the same error, but not on Expo (as reported by an Author) then this is a separate issue and should be reported separately.
@clementbmn Currently I don't have the environment to repro your issue so this will take a bigger amount of time unless there's someone who would handle this before. Thank you for your patience.
Hi @BartoszKlonowski, Surely will open an issue for that and also share a repo, using which you can reproduce this issue.
Hi @BartoszKlonowski, Today i tried it in a brand new project and it works fine for both android and ios then i tried to add it in my current project and this time it works without any issue. For more info my project configuration is - System: OS: macOS 12.3 CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz Memory: 4.68 GB / 16.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 16.13.2 - /usr/local/bin/node Yarn: 1.22.17 - /usr/local/bin/yarn npm: 8.1.2 - /usr/local/bin/npm Watchman: 2022.01.10.00 - /usr/local/bin/watchman Managers: CocoaPods: 1.11.3 - /usr/local/bin/pod SDKs: iOS SDK: Platforms: DriverKit 21.4, iOS 15.4, macOS 12.3, tvOS 15.4, watchOS 8.5 Android SDK: Not Found IDEs: Android Studio: 2020.3 AI-203.7717.56.2031.7935034 Xcode: 13.3/13E113 - /usr/bin/xcodebuild Languages: Java: 11.0.11 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 17.0.2 => 17.0.2 react-native: 0.67.4 => 0.67.4 react-native-macos: Not Found npmGlobalPackages: react-native: Not Found
@rahulnainwal107 Great, I'm glad your issue is gone. Thank you for taking the time to come back with that info.
@clementbmn I think I found a fix? I had this problem with an Expo Managed app (SDK 44), I built the app again after installing the package with expo install and when I ran it on my simulator it was working fine
@clementbmn Did you try the full rebuild and reinstall trick that helped all others facing the same error?
Hi, sorry I finally ended up ejecting my expo project for some other reason, and did not have the problem anymore
For New User: Remember to rebuild your android app.
npx react-native run-android
or whatever you are using for rebuilding app.
In Expo this problem does not reveal with Expo Go. If you use Development Build instead you will get the error. I was using expo-video-player and i did not have the problem but after the development or production then i saw it.
So what did i do?
Installing latest version of @react-native-community/slider and create a new development build is the answer for my case. Actually expo-video-player package uses this package.
"@react-native-community/slider": "^4.4.3",
"expo": "~49.0.5",
"expo-video-player": "^2.2.0",