Closed reason211 closed 7 years ago
I'm having issues with BVLinearGradient as well. RN 0.40 does introduce some breaking changes so it's likely that the shoutem team has not yet released a version that supports RN 0.40.
Can someone please confirm whether or not Shoutem UI and Animations support RN 0.40 and if not, when should we expect a new release?
Edit: Check this out - #124
Open your project in xcode and navigate to libraries/BVLinearGradient.xcodeproj/BVLinearGradient
In each of the four files within that directory, you need to change a few import statements at the top of the file. Look for input statements with a prefix of RCT like:
#import "RCTBridge.h"
#import "RCTViewManager.h"
#import "RCTView.h"
Now change each of those statements to this:
#import <React/RCTBridge.h>
#import <React/RCTViewManager.h>
#import <React/RCTView.h>
Moving forward you may discover that other libraries are giving you issues like this. Until these libraries are updated to work with the latest 0.40 release of react native, you'll have to continue with workarounds like this.
Simply put, you just need to reformat import statements for libraries prefixed with RCT from being enclosed like this: "{library name}"
To being enclosed like this: <React/{library name} >
This fix should work for most other issues related to these breaking changes that came with 0.40. Version 4.0 of react-native-vector-icons and the latest version of react-native-share also fixed some issues that Shoutem/UI is currently facing. Just waiting on them to roll out a new update that includes these latest updates.
@tedjames It works! Your help was greatly appreciated!
@tedjames You are a life saver :D thanks mate
Is this in 0.10.9? Getting similar errors in RN 0.41.2
Getting the same errors in 0.41.2 too :( any idea when this is going to get pushed?
Also, if you get a similar error in relation to the vector icons library. Thanks to the solution above, find the RNVectorIcons.xcodeproj/RNVectorIconsManager/RNVectorIconsManager.h, and replace:
#import "RCTLog.h"
with
#import <React/RCTLog.h>
Thanks, @tedjames
Note that this is fixed in more recent versions of react-native-linear-gradient. In particular, version 2.0.0 solved it for me.
Guys, there is 0.12.0-rc.1 available at npm with dist-tag rc so could you try it and verify does it fix this issue? On Sun, 19 Mar 2017 at 00:38, Ryan Homer notifications@github.com wrote:
Note that this is fixed in more recent versions of react-native-linear-gradient. In particular, version 2.0.0 solved it for me.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/shoutem/ui/issues/134#issuecomment-287583038, or mute the thread https://github.com/notifications/unsubscribe-auth/AEYJkbF0DJfKOF8ZfqCzcPfxEfgWX1i5ks5rnGrygaJpZM4LoMOm .
import "RCTBridge.h"
import "RCTViewManager.h"
import "RCTView.h"
@tedjames my files are already have statements like you mentioned but then also i m getting error
I follow the following steps to do step by step, but it can not be compiled successfully.
Build Environment: Xcode: Version 8.2.1 (8C1002) react-native": "0.40.0" node: v6.3.1 npm: 3.10.3
Is it because shoutem-ui does not support react-native 0.40.0 yet ?