React-native-orientation: Inside the RN0.41, can't find RCTBridgeModule.h

Created on 7 Mar 2017  路  11Comments  路  Source: yamill/react-native-orientation

Inside the react-native, after installing this plugin, you can't find RCTBridgeModule.h at compile time
Need to

import "RCTBridgeModule.h"

Modified into

import

Most helpful comment

+1 for merging this trivial solution into master

All 11 comments

Hi. This fix could cause problems at versions less than 0.41?

This snippet should be work.

#ifdef __has_include(<React/RCTBridgeModule.h>)
#import <React/RCTBridgeModule.h>
#else
#import "RCTBridgeModule.h"
#endif

+1 for merging this trivial solution into master

@jalieven it's been merged with latest PR 5a16ac8a3f96e12969d86a1dd1f6d548efc213b2. Closing this for now. Let me know if anyone faces further issues. @darleikroth these changes should be backwards compatible, so should not affect RN apps older than 0.40.

Nice. Thx!

Hi I'm having this same issue with RN version 0.36. Any ideas?

@frankrod where is your react-native-orientation package pointed to inside your package.json file? It has to be mapped to this git repo on the master branch.

@andrerfneves "react-native-orientation": "git+https://github.com/yamill/react-native-orientation.git"

@frankrod I need to be able to test on a 0.36RN version. I'll need sometime to look into it. I'll get back to you shortly.

@frankrod try replacing the line in package.json with "react-native-orientation": "^1.17.0" => I'm on RN 0.37 and this was the only way I could get past this issue when compiling.

@dozel @frankrod if you are having to point to the NPM package version 1.17.0, then it means that the commits to upgrade to 0.40+ are not working correctly with backwards compatibility. @frankrod, go ahead and follow @dozel's idea, and I'll try and look at this sometime tomorrow.

Was this page helpful?
0 / 5 - 0 ratings