Reputation: 16482
I'm following the guide here to create a Native Module in React Native. I selected Swift & Kotlin for the language.
https://reactnative.dev/docs/native-modules-setup
I go through the setup, and it creates two projects. One is an example app and the top level is a library project (AwesomeModule.xcodeproj) for the module. When I open up the iOS library project for the Turbo Module in Xcode I get this errors.
'React/RCTBridgeModule.h' file not found
Here is a screenshot of that directory. It just generates a project file without a workspace.
How do I generate a Workspace in this library project so I can run it independently of the example project?
Upvotes: 1
Views: 1183
Reputation: 25343
for making a library, we don't need to make xcworkspace
separately for a library or native modules, for pod support in your library or native modules you can use project_root/project.podspec
I would suggest using react-native-builder-bob for creating native turbo modules with an example folder. it is easy to use
npx create-react-native-library@latest react-native-awesome-library
Upvotes: 3