Chapter 7. Modules and Native Code
Project with Native Code Required
The examples in this section apply only to projects created with react-native-init and ejected projects created with create-react-native-app. For more information, see Appendix C.
In Chapter 6, we looked at some of the APIs that React Native exposes for interacting with the host platform. Because support for those APIs is built into React Native, they’re quite easy to use. What happens when we want to use an API that isn’t supported by React Native?
In this chapter, we’ll look at how to install modules written by members of the React Native community using npm. We’ll also take a closer look at one such module,
react-native-video, and learn how the
Though we will be looking at some Objective-C and Java code this chapter, don’t be alarmed! We’ll be taking it slowly. A full introduction to mobile development for iOS and Android is beyond the scope of this book, but we’ll walk through some examples together.