Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ A screen record module for React Native.

- Support Android
- minSdkVersion = 26
- compileSdkVersion = 34
- targetSdkVersion = 34
- compileSdkVersion = 36
- targetSdkVersion = 36
- use [HBRecorder](https://github.com/HBiSoft/HBRecorder)

## Installation

```sh
npm install react-native-record-screen
npm install https://github.com/alexpap98/react-native-record-screen.git#fix/react-native-support-0.81.0
```

### iOS
Expand Down
40 changes: 25 additions & 15 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ buildscript {
}

dependencies {
classpath "com.android.tools.build:gradle:7.2.1"
classpath "com.android.tools.build:gradle:8.5.2"
// noinspection DifferentKotlinGradleVersion
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
Expand All @@ -21,7 +21,6 @@ def isNewArchitectureEnabled() {
apply plugin: "com.android.library"
apply plugin: "kotlin-android"


def appProject = rootProject.allprojects.find { it.plugins.hasPlugin('com.android.application') }

if (isNewArchitectureEnabled()) {
Expand All @@ -46,37 +45,45 @@ def supportsNamespace() {
}

android {
if (supportsNamespace()) {
namespace "com.recordscreen"
compileSdk getExtOrIntegerDefault("compileSdkVersion")

namespace "com.recordscreen"

sourceSets {
main {
manifest.srcFile "src/main/AndroidManifestNew.xml"
}
sourceSets {
main {
manifest.srcFile "src/main/AndroidManifestNew.xml"
}
}
compileSdkVersion getExtOrIntegerDefault("compileSdkVersion")

defaultConfig {
minSdkVersion getExtOrIntegerDefault("minSdkVersion")
targetSdkVersion getExtOrIntegerDefault("targetSdkVersion")
minSdk getExtOrIntegerDefault("minSdkVersion")
targetSdk getExtOrIntegerDefault("targetSdkVersion")
buildConfigField "boolean", "IS_NEW_ARCHITECTURE_ENABLED", isNewArchitectureEnabled().toString()
}

buildTypes {
release {
minifyEnabled false
}
}

lintOptions {
lint {
disable "GradleCompatible"
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}

kotlinOptions {
jvmTarget = "17"
}

packagingOptions {
pickFirst '**/libc++_shared.so'
pickFirst '**/libjsc.so'
}
}

repositories {
Expand All @@ -92,6 +99,9 @@ dependencies {
//noinspection GradleDynamicVersion
implementation "com.facebook.react:react-native:+"
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation "androidx.appcompat:appcompat:1.7.0"
implementation "androidx.activity:activity-ktx:1.9.3"
implementation "androidx.fragment:fragment-ktx:1.8.5"
implementation "com.github.HBiSoft:HBRecorder:3.0.3"
}

Expand All @@ -101,4 +111,4 @@ if (isNewArchitectureEnabled()) {
libraryName = "RecordScreen"
codegenJavaPackageName = "com.recordscreen"
}
}
}
10 changes: 5 additions & 5 deletions android/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
RecordScreen_kotlinVersion=1.7.0
RecordScreen_minSdkVersion=21
RecordScreen_targetSdkVersion=31
RecordScreen_compileSdkVersion=31
RecordScreen_ndkversion=21.4.7075529
RecordScreen_kotlinVersion=2.1.20
RecordScreen_minSdkVersion=23
RecordScreen_targetSdkVersion=36
RecordScreen_compileSdkVersion=36
RecordScreen_ndkversion=27.1.12297006
Loading