Skip to content

How to manually link the lib in the iOS example app #506

Closed Answered by roni-castro-glooko
roni-castro-glooko asked this question in Q&A
Discussion options

You must be logged in to vote

This is an example I used of configuring an external native module generated by react-native-bob-builder and allowing the injection of dependencies to it.

The React-native docs seem incomplete for manual linking for iOS, so I didn't actually follow it 100%, instead, I created a solution based on some other repos I found.

  • Added react-native-config.js to disable automatic linking of this external lib for iOS also.
module.exports = {
  dependencies: {
    ['myLibJSPackageName']: {
      platforms: {
        android: null,
        ios: null, // Disable ios linking
        // Add more platforms to disable auto-linking for them too
      },
    },
  },
};
  • Add to the lib pod to the target
ta…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by roni-castro-glooko
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant