react-native-blur icon indicating copy to clipboard operation
react-native-blur copied to clipboard

Error: Invariant Violation: Native component for "BlurView" does not exist

Open VicFrolov opened this issue 8 years ago • 7 comments

react-native 0.52.0

just installed blurview:

import { BlurView } from 'react-native-blur';


render() {
  // some code
 <BlurView blurType="light" style={styles.blur} />
 // more code
}


getting this error: screen shot 2018-01-19 at 5 55 11 pm

EDIT: This seems to also be occuring for react-native-linear-gradient

VicFrolov avatar Jan 20 '18 02:01 VicFrolov

Solution in #249; add the libRNBlur.a manually to Build Phases

ashleydw avatar Feb 05 '18 20:02 ashleydw

Can you guys provide me more info on how to add the libRNBlur.a manually to Build Phases?

andrescalco avatar Feb 06 '18 13:02 andrescalco

@ashleydw Where do I find libRNBlur.a? Running find . -name "libRNBlur.a" gives me nothing..

pcoltau avatar Feb 13 '18 15:02 pcoltau

see https://facebook.github.io/react-native/docs/linking-libraries-ios.html

ashleydw avatar Feb 13 '18 21:02 ashleydw

For people using Codepods instead of the manual linking, make sure to run pod install on ios folder after the react-native link react-native-blur

andfk avatar Apr 02 '18 15:04 andfk

For some reason in this project react-native link doesn't work. The following solves this issue. Open XCode, go to your workspace. Right click on your project and press on Add files to "<project name". Go to node_modules -> react-native-blur -> ios and select RNBlur.xcodeproj and press Add. Press on your project go to Build Phases -> Link Binary with Libraries press on the + and add libRNBlur.a. Now it should work

VladyslavKochetkov avatar Dec 10 '18 17:12 VladyslavKochetkov

I'm using cocoapods and this still doesn't work. I get an error on <React/RCTComponent.h>

React/RCTComponent.h file not found,

I've tried linking manually as well, no luck

bensont1 avatar May 13 '19 01:05 bensont1