Quantcast
Channel: Active questions tagged react-native+ios - Stack Overflow
Viewing all articles
Browse latest Browse all 16766

Upgrading React Native plugin to support autolinking and React Native versions 0.6>=

$
0
0

I am fairly new to React Native but am helping manage a React Native plugin and would like some guidance for upgrading it so that it is compatible with auto linking and React Native versions 0.60 and up in iOS.

Our plugin currently only works with React Native up to and including 0.59.x through the react-native link command and sometimes involves manually dragging our xcodeproj and .a binary inside Xcode.

When trying to instrument our plugin with a blank hello world React Native app of version 0.60.5, after react-native link and dragging in Xcode, we get an error saying rctbridgemodule.h not found and have to add React.xcodeproj too. This however doesn’t work on some apps we’ve tried. Furthermore the issue is in newer versions of React eg 0.61.4, the React.xcodeproj file is no longer in the React folder in node_modules. 

I’ve had a look at the What do I need to have in my package to make it work? Section in this link: https://github.com/react-native-community/cli/blob/master/docs/autolinking.md

But to me its not very clear how we should be configuring a pod spec in the root of our repo. Our package is scoped also. I’m assuming that there shouldn’t need to be any changes to the actual code of our plugin but rather just some modifications to our pod spec and package configuration. Any guidance in how this works and how to upgrade our plugin to support versions 0.6 and above would be greatly appreciated. Thanks!


Viewing all articles
Browse latest Browse all 16766

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>