Skip to content
A Camera component for React Native. Also supports barcode scanning!
Java Objective-C C++ C# JavaScript Ruby Other
Branch: master
Clone or download

Latest commit

semantic-release-bot chore(release): 3.26.0 [skip ci]
# [3.26.0](v3.25.0...v3.26.0) (2020-05-14)

### Features

* **android:** expose an ability to change the frames per second  ([#2834](#2834)) ([04e6f06](04e6f06))
Latest commit e55893b May 14, 2020

Files

Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci ci: changing circle to use rn-orb May 11, 2020
.github feat(funding): add FUNDING.yml [skip ci] Jun 13, 2019
android feat(android): expose an ability to change the frames per second (#2834) May 14, 2020
docs feat(android): expose an ability to change the frames per second (#2834) May 14, 2020
examples feat(touch): Feature/add on tap events (#2827) May 12, 2020
ios feat(touch): Feature/add on tap events (#2827) May 12, 2020
src feat(android): expose an ability to change the frames per second (#2834) May 14, 2020
types feat(touch): Feature/add on tap events (#2827) May 12, 2020
website doc(tidelift): add tidelift for enterprise Oct 19, 2019
windows Windows fixes Apr 23, 2020
.dockerignore feat(docs): Add docusaurus (#2293) Jun 2, 2019
.eslintIgnore feat(test): add on-device tests (#2792) Apr 14, 2020
.eslintrc docs(rn-camera): add rncamera-example without face detection (#1979) … Dec 11, 2018
.flowconfig chore(lint): fix lint to make ci work Apr 15, 2018
.gitattributes disable git large files Feb 1, 2018
.gitignore feat(mlkit): Migrate Face, Barcode and Text Recognition to Firebase M… Mar 11, 2019
.npmignore feat(npm): ignore docs and publish 3.11.0 Nov 20, 2019
.prettierrc docs(rn-camera): add rncamera-example without face detection (#1979) … Dec 11, 2018
CHANGELOG.md chore(changelog): add link to github releases [skip ci] Nov 12, 2018
Dockerfile feat(docs): Add docusaurus (#2293) Jun 2, 2019
LICENSE Initial commit Apr 1, 2015
README.md doc(tidelift): add security section on readme Nov 8, 2019
THIRD-PARTY-LICENSES rename expo to simple RN, add js files, and export them inside the sa… Jan 1, 2018
commitlint.config.js chore(semantic-release): setup semantic-release for automated publish… Nov 12, 2018
docker-compose.yml feat(docs): Add docusaurus (#2293) Jun 2, 2019
package.json chore(release): 3.26.0 [skip ci] May 14, 2020
react-native-camera.podspec feat(mlkit): add mlkit barcode detection ios (#2209) Apr 16, 2019
yarn.lock feat(android): Update Gradle Wrapper and plugin, fix files (#2818) May 5, 2020

README.md

React Native Camera Backers on Open Collective Sponsors on Open Collective npm version npm downloads

Docs

Follow our docs here https://react-native-community.github.io/react-native-camera/

Sponsors

If you use this library on your commercial/personal projects, you can help us by funding the work on specific issues that you choose by using IssueHunt.io!

This gives you the power to prioritize our work and support the project contributors. Moreover it'll guarantee the project will be updated and maintained in the long run.

issuehunt-image

react-native-camera for enterprise

Available as part of the Tidelift Subscription

The maintainers of react-native-camera and thousands of other packages are working with Tidelift to deliver commercial support and maintenance for the open source dependencies you use to build your applications. Save time, reduce risk, and improve code health, while paying the maintainers of the exact dependencies you use. Learn more.

Open Collective

You can also fund this project using open collective

Backers

Support us with a monthly donation and help us continue our activities. [Become a backer]

Sponsors

Become a sponsor and get your logo on our README on Github with a link to your site. [Become a sponsor]

The comprehensive camera module for React Native.

Supports:

  • photographs.
  • videos
  • face detection (Android & iOS only)
  • barcode scanning
  • text recognition (optional installation for iOS using CocoaPods)

Example import

import { RNCamera, FaceDetector } from 'react-native-camera';

How to use master branch?

We recommend using the releases from npm, however if you need some features that are not published on npm yet you can install react-native-camera from git.

yarn: yarn add react-native-camera@git+https://git@github.com/react-native-community/react-native-camera.git

npm: npm install --save react-native-camera@git+https://git@github.com/react-native-community/react-native-camera.git

Contributing

  • Pull Requests are welcome, if you open a pull request we will do our best to get to it in a timely manner
  • Pull Request Reviews are even more welcome! we need help testing, reviewing, and updating open PRs
  • If you are interested in contributing more actively, please contact me (same username on Twitter, Facebook, etc.) Thanks!
  • We are now on Open Collective! Contributions are appreciated and will be used to fund core contributors. more details
  • If you want to help us coding, join Expo slack https://slack.expo.io/, so we can chat over there. (#react-native-camera)
Permissions

To use the camera,

  1. On Android you must ask for camera permission:
  <uses-permission android:name="android.permission.CAMERA" />

To enable video recording feature you have to add the following code to the AndroidManifest.xml:

  <uses-permission android:name="android.permission.RECORD_AUDIO"/>
  <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
  <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

5j2jduk

  1. On iOS, you must update Info.plist with a usage description for camera
...
<key>NSCameraUsageDescription</key>
<string>Your own description of the purpose</string>
...
	

For more information on installation, please refer to installation requirements.

For general introduction, please take a look into this RNCamera.

Security contact information

To report a security vulnerability, please use the

Tidelift security contact.

Tidelift will coordinate the fix and disclosure.

You can’t perform that action at this time.