Skip to content

Latest commit

 

History

History
20 lines (14 loc) · 879 Bytes

File metadata and controls

20 lines (14 loc) · 879 Bytes

Lesson 11: Add native modules to react-native-windows app

react-native-windows supports the link command for linking native dependencies to your project. We'll use this to link the react-native-camera dependency that was installed in Lesson 4.

Link the native dependency

Using the React Native CLI link command, add the react-native-camera native dependency to your solution.

Add the necessary device capabilities to your app package manifest

Open windows\<project>\Package.appxmanifest and add the following to the <Capabilities> section:

    <uap:Capability Name="picturesLibrary" />
    <DeviceCapability Name="microphone" />
    <DeviceCapability Name="webcam" />

Exit Criteria

  1. MainReactNativeHost.cs file includes reference to react-native-camera package.
  2. App still builds and runs successfully with run-windows command.