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 🙏

© 2025 – Pkg Stats / Ryan Hefner

react-native-record-screen-extended

v0.6.3

Published

react-native-record-screen with enhanced MediaProjectionConfig support for Android 14+

Downloads

108

Readme

Stand With Ukraine

react-native-record-screen-extended

A screen record module for React Native with enhanced MediaProjectionConfig support for Android 14+.

🆕 What's New in Extended Version?

Enhanced Android 14+ Support: This fork adds a new startRecordingEntireScreen() method that uses Android's MediaProjectionConfig.createConfigForDefaultDisplay() API to block the "Single app" recording option on Android 14+, forcing entire screen recording for security and compliance requirements.

Key Differences from Original Package

| Feature | Original Package | Extended Package ✨ | |---------|-----------------|----------------------| | Basic screen recording | ✅ startRecording() | ✅ startRecording() (same behavior) | | "Single app" option (Android 14+) | ✅ Always allowed | ✅ Choice: Allow OR Block | | Force entire screen recording | ❌ Not possible | ✅ New: startRecordingEntireScreen() | | iOS Support | ✅ | ✅ (no changes) | | Backward Compatible | - | ✅ 100% compatible |

Use Case: Perfect for security applications, compliance requirements, and ensuring consistent recording behavior across Android versions.


  • Support iOS >= 11.0 (Simulator is not work)

  • Support Android

    • minSdkVersion = 26
    • compileSdkVersion = 34
    • targetSdkVersion = 34
    • use HBRecorder

Installation

npm install react-native-record-screen-extended

iOS

  1. Add the permission strings to your Info.plist
<key>NSCameraUsageDescription</key>
<string>Please allow use of camera</string>
<!-- If you intend to use the microphone -->
<key>NSMicrophoneUsageDescription</key>
<string>Please allow use of microphone</string>
  1. pod install
npx pod-install
  1. Add ReplayKit.framework at Link Binary With Libraries

Add ReplayKit.framework at Link Binary With Libraries

Android

  1. Add the permissions to your AndroidManifest.xml
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<!-- If you intend to use the microphone -->
<uses-permission android:name="android.permission.RECORD_AUDIO" />

Usage

Recording full screen

import RecordScreen, { RecordingResult } from 'react-native-record-screen-extended';

// recording start
const res = RecordScreen.startRecording().catch((error) => console.error(error));
if (res === RecordingResult.PermissionError) {
  // user denies access
}

// recording stop
const res = await RecordScreen.stopRecording().catch((error) =>
  console.warn(error)
);
if (res) {
  const url = res.result.outputURL;
}

Setting microphone

default true.

// mic off
RecordScreen.startRecording({ mic: false }).catch((error) =>
  console.error(error)
);

// recording stop
const res = await RecordScreen.stopRecording().catch((error) =>
  console.warn(error)
);
if (res) {
  const url = res.result.outputURL;
}

Adjusting bitrate / frame rate

RecordScreen.startRecording({
  bitrate: 1024000, // default 236390400
  fps: 24, // default 60
})

Clean Sandbox

RecordScreen.clean();

🆕 Enhanced Screen Recording (Android 14+)

New Method: startRecordingEntireScreen()

import RecordScreen from 'react-native-record-screen-extended';

// Force entire screen recording (blocks "Single app" option)
await RecordScreen.startRecordingEntireScreen({
  fps: 30,
  bitrate: 1000000,
  mic: true
});

Platform Behavior

  • Android 14+: Uses MediaProjectionConfig to block "Single app" recording
  • Android 13-: Falls back to regular behavior
  • iOS: Uses regular startRecording() (no "Single app" option exists)

Migration Guide

  • Existing code: No changes needed, startRecording() works as before
  • New feature: Use startRecordingEntireScreen() when you need to enforce full screen recording

Use Cases

  • Security applications requiring full context
  • Compliance and audit requirements
  • Consistent UX across Android versions

License

MIT