npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

react-native-pro-camera

v1.3.0

Published

An elegant, high-performance camera library for React Native powered by CameraX and AVFoundation. Features zero-config installation, automatic permissions, native tap-to-focus, flash toggle, grid overlays, and instantaneous photo capture.

Readme

react-native-pro-camera

A high-performance camera library for React Native built with CameraX (Android) and AVFoundation (iOS).

Features

  • Android & iOS support
  • React Native New Architecture
  • React Native Old Architecture
  • Ready-to-use camera screen
  • Custom camera view
  • Tap to focus
  • Flash control
  • Front & back camera
  • Photo preview
  • Save to gallery support

Installation

npm install react-native-pro-camera react-native-svg react-native-safe-area-context

or

yarn add react-native-pro-camera react-native-svg react-native-safe-area-context

Note react-native-svg and react-native-safe-area-context are required peer dependencies.


iOS Setup

Install CocoaPods:

cd ios
pod install
cd ..

Add the following permission to Info.plist:

<key>NSCameraUsageDescription</key>
<string>This app requires camera access to capture photos.</string>

Android Setup

No manual setup is required.

Recommended Lock your app to portrait mode to avoid preview rotation issues.

<activity
    android:name=".MainActivity"
    android:screenOrientation="portrait" />

Usage

Ready-to-use Camera

import { ProCameraScreen } from "react-native-pro-camera";

export default function App() {
  return (
    <ProCameraScreen
      showPreviewOnCapture
      saveToPhotos={false}
      initialLensFacing="back"
      initialFlashMode="off"
      onPhotoCaptured={(photo) => {
        console.log(photo);
      }}
    />
  );
}

Custom Camera

import { useRef } from "react";
import {
  ProCameraView,
  checkPermissions,
  requestPermissions,
} from "react-native-pro-camera";

const cameraRef = useRef(null);

async function capture() {
  const photo = await cameraRef.current?.takePicture({
    saveToPhotos: false,
  });

  console.log(photo);
}

<ProCameraView
  ref={cameraRef}
  style={{ flex: 1 }}
/>;

API

Methods

| Method | Description | |---------|-------------| | checkPermissions() | Check camera permission. | | requestPermissions() | Request camera permission. | | takePicture(options?) | Capture a photo. |

takePicture()

takePicture({
  saveToPhotos?: boolean;
});

Photo Result

{
  uri: string;
  path: string;
  width: number;
  height: number;
  mediaStoreUri?: string;
}

ProCameraScreen Props

| Prop | Default | |------|---------| | showPreviewOnCapture | false | | saveToPhotos | false | | initialLensFacing | "back" | | initialFlashMode | "off" | | onPhotoCaptured | - | | onError | - |


ProCameraView Props

| Prop | Default | |------|---------| | lensFacing | "back" | | flashMode | "off" | | onFocusTap | - | | onError | - |


License

MIT