Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Warning: Native component for "BVLinearGradient" does not exist

I'm trying to implement react-native-linear-gradient but I get the following error once I import the library into my react-native component:

import LinearGradient from 'react-native-linear-gradient'

enter image description here

I can successfully compile the project in XCode and the gradient shows up on the physical iPhone but it doesn't in the Simulator.

Has anyone dealt with this problem before?

Again, the problem is that react-native (iOS Simulator) can't find the library but the BVLinearGradient library are there in Xcode and the project compiles successfully.

enter image description here

Thanks

like image 908
Thomas Dittmar Avatar asked Mar 29 '17 23:03

Thomas Dittmar


1 Answers

I see you're using RN 0.6.x, so you don't have to link. You ought to go iOS direction and run this command.

"pod install"

And you should read README of linear gradient carefully for iOS integration.

like image 145
Kubilay Kiymaci Avatar answered Oct 26 '22 10:10

Kubilay Kiymaci