1
0
mirror of https://gitcode.com/gh_mirrors/re/react-native-pushy.git synced 2025-09-19 00:10:42 +08:00
Code Issues Packages Projects Releases Wiki Activity GitHub Gitee

Compare commits

..

8 Commits

Author SHA1 Message Date
sunny.luo
73e2f72b0f v10.19.1 2024-12-11 17:23:44 +08:00
CrazyBigTree
e6efa55bd5 fix: check module activity null pointer. (#457)
Co-authored-by: 黄世城 <huangshicheng@xgd.com>
2024-12-10 20:42:34 +08:00
sunny.luo
d6b1205fb9 v10.19.0 2024-12-10 20:05:52 +08:00
sunny.luo
0382cfaec3 check activity 2024-12-10 20:03:13 +08:00
sunnylqm
6ee34ebd24 support 0.76 2024-12-07 16:43:22 +08:00
sunnylqm
09df53a6ab update example to 0.76.3 2024-12-06 23:33:04 +08:00
sunny.luo
be93641392 v10.17.1 2024-12-02 16:20:37 +08:00
sunny.luo
946a5db7e9 catch network error 2024-12-02 16:16:18 +08:00
23 changed files with 2293 additions and 771 deletions

View File

@@ -1,7 +1,6 @@
apply plugin: "com.android.application" apply plugin: "com.android.application"
apply plugin: "org.jetbrains.kotlin.android"
apply plugin: "com.facebook.react" apply plugin: "com.facebook.react"
apply plugin: "kotlin-android"
apply plugin: "kotlin-android-extensions"
/** /**
* This is the configuration block to customize your React Native Android app. * This is the configuration block to customize your React Native Android app.
@@ -50,6 +49,7 @@ react {
// //
// The list of flags to pass to the Hermes compiler. By default is "-O", "-output-source-map" // The list of flags to pass to the Hermes compiler. By default is "-O", "-output-source-map"
// hermesFlags = ["-O", "-output-source-map"] // hermesFlags = ["-O", "-output-source-map"]
autolinkLibrariesWithApp()
} }
/** /**
@@ -106,21 +106,14 @@ android {
} }
} }
dependencies { dependencies {
// The version of react-native is set by the React Native Gradle Plugin // The version of react-native is set by the React Native Gradle Plugin
implementation("com.facebook.react:react-android") implementation("com.facebook.react:react-android")
debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}")
debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") {
exclude group:'com.squareup.okhttp3', module:'okhttp'
}
debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}")
if (hermesEnabled.toBoolean()) { if (hermesEnabled.toBoolean()) {
implementation("com.facebook.react:hermes-android") implementation("com.facebook.react:hermes-android")
} else { } else {
implementation jscFlavor implementation jscFlavor
} }
} }
apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project)

View File

@@ -1,73 +0,0 @@
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* <p>This source code is licensed under the MIT license found in the LICENSE file in the root
* directory of this source tree.
*/
package com.awesomeproject;
import android.content.Context;
import com.facebook.flipper.android.AndroidFlipperClient;
import com.facebook.flipper.android.utils.FlipperUtils;
import com.facebook.flipper.core.FlipperClient;
import com.facebook.flipper.plugins.crashreporter.CrashReporterPlugin;
import com.facebook.flipper.plugins.databases.DatabasesFlipperPlugin;
import com.facebook.flipper.plugins.fresco.FrescoFlipperPlugin;
import com.facebook.flipper.plugins.inspector.DescriptorMapping;
import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin;
import com.facebook.flipper.plugins.network.FlipperOkhttpInterceptor;
import com.facebook.flipper.plugins.network.NetworkFlipperPlugin;
import com.facebook.flipper.plugins.react.ReactFlipperPlugin;
import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin;
import com.facebook.react.ReactInstanceEventListener;
import com.facebook.react.ReactInstanceManager;
import com.facebook.react.bridge.ReactContext;
import com.facebook.react.modules.network.NetworkingModule;
import okhttp3.OkHttpClient;
public class ReactNativeFlipper {
public static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) {
if (FlipperUtils.shouldEnableFlipper(context)) {
final FlipperClient client = AndroidFlipperClient.getInstance(context);
client.addPlugin(new InspectorFlipperPlugin(context, DescriptorMapping.withDefaults()));
client.addPlugin(new ReactFlipperPlugin());
client.addPlugin(new DatabasesFlipperPlugin(context));
client.addPlugin(new SharedPreferencesFlipperPlugin(context));
client.addPlugin(CrashReporterPlugin.getInstance());
NetworkFlipperPlugin networkFlipperPlugin = new NetworkFlipperPlugin();
NetworkingModule.setCustomClientBuilder(
new NetworkingModule.CustomClientBuilder() {
@Override
public void apply(OkHttpClient.Builder builder) {
builder.addNetworkInterceptor(new FlipperOkhttpInterceptor(networkFlipperPlugin));
}
});
client.addPlugin(networkFlipperPlugin);
client.start();
// Fresco Plugin needs to ensure that ImagePipelineFactory is initialized
// Hence we run if after all native modules have been initialized
ReactContext reactContext = reactInstanceManager.getCurrentReactContext();
if (reactContext == null) {
reactInstanceManager.addReactInstanceEventListener(
new ReactInstanceEventListener() {
@Override
public void onReactContextInitialized(ReactContext reactContext) {
reactInstanceManager.removeReactInstanceEventListener(this);
reactContext.runOnNativeModulesQueueThread(
new Runnable() {
@Override
public void run() {
client.addPlugin(new FrescoFlipperPlugin());
}
});
}
});
} else {
client.addPlugin(new FrescoFlipperPlugin());
}
}
}
}

View File

@@ -65,6 +65,5 @@ public class MainApplication extends Application implements ReactApplication {
// If you opted-in for the New Architecture, we load the native entry point for this app. // If you opted-in for the New Architecture, we load the native entry point for this app.
DefaultNewArchitectureEntryPoint.load(); DefaultNewArchitectureEntryPoint.load();
} }
ReactNativeFlipper.initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
} }
} }

View File

@@ -1,15 +1,11 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript { buildscript {
ext { ext {
buildToolsVersion = "34.0.0" buildToolsVersion = "35.0.0"
minSdkVersion = 23 minSdkVersion = 24
compileSdkVersion = 34 compileSdkVersion = 35
targetSdkVersion = 34 targetSdkVersion = 34
ndkVersion = "26.1.10909125" ndkVersion = "26.1.10909125"
kotlinVersion = "1.9.24" kotlinVersion = "1.9.24"
kotlin_version = '1.9.24'
} }
repositories { repositories {
google() google()
@@ -21,3 +17,5 @@ buildscript {
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin") classpath("org.jetbrains.kotlin:kotlin-gradle-plugin")
} }
} }
apply plugin: "com.facebook.react.rootproject"

View File

@@ -21,11 +21,6 @@ org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m
# Android operating system, and which are packaged with your app's APK # Android operating system, and which are packaged with your app's APK
# https://developer.android.com/topic/libraries/support-library/androidx-rn # https://developer.android.com/topic/libraries/support-library/androidx-rn
android.useAndroidX=true android.useAndroidX=true
# Automatically convert third-party libraries to use AndroidX
android.enableJetifier=true
# Version of flipper SDK to use with React Native
FLIPPER_VERSION=0.182.0
# Use this property to specify which architecture you want to build. # Use this property to specify which architecture you want to build.
# You can also override it from the CLI using # You can also override it from the CLI using

View File

@@ -15,6 +15,8 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
# #
# SPDX-License-Identifier: Apache-2.0
#
############################################################################## ##############################################################################
# #
@@ -55,7 +57,7 @@
# Darwin, MinGW, and NonStop. # Darwin, MinGW, and NonStop.
# #
# (3) This script is generated from the Groovy template # (3) This script is generated from the Groovy template
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt # https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# within the Gradle project. # within the Gradle project.
# #
# You can find Gradle at https://github.com/gradle/gradle/. # You can find Gradle at https://github.com/gradle/gradle/.
@@ -83,10 +85,9 @@ done
# This is normally unused # This is normally unused
# shellcheck disable=SC2034 # shellcheck disable=SC2034
APP_BASE_NAME=${0##*/} APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit # Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. ' "$PWD" ) || exit
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# Use the maximum available, or set MAX_FD != -1 to use that value. # Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum MAX_FD=maximum
@@ -133,10 +134,13 @@ location of your Java installation."
fi fi
else else
JAVACMD=java JAVACMD=java
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. if ! command -v java >/dev/null 2>&1
then
die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the Please set the JAVA_HOME variable in your environment to match the
location of your Java installation." location of your Java installation."
fi
fi fi
# Increase the maximum file descriptors if we can. # Increase the maximum file descriptors if we can.
@@ -144,7 +148,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
case $MAX_FD in #( case $MAX_FD in #(
max*) max*)
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045 # shellcheck disable=SC2039,SC3045
MAX_FD=$( ulimit -H -n ) || MAX_FD=$( ulimit -H -n ) ||
warn "Could not query maximum file descriptor limit" warn "Could not query maximum file descriptor limit"
esac esac
@@ -152,7 +156,7 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
'' | soft) :;; #( '' | soft) :;; #(
*) *)
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045 # shellcheck disable=SC2039,SC3045
ulimit -n "$MAX_FD" || ulimit -n "$MAX_FD" ||
warn "Could not set maximum file descriptor limit to $MAX_FD" warn "Could not set maximum file descriptor limit to $MAX_FD"
esac esac
@@ -197,11 +201,15 @@ if "$cygwin" || "$msys" ; then
done done
fi fi
# Collect all arguments for the java command;
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
# shell script including quotes and variable substitutions, so put them in DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
# double quotes to make sure that they get re-expanded; and
# * put everything else in single quotes, so that it's not re-expanded. # Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.
set -- \ set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \ "-Dorg.gradle.appname=$APP_BASE_NAME" \

View File

@@ -13,6 +13,8 @@
@rem See the License for the specific language governing permissions and @rem See the License for the specific language governing permissions and
@rem limitations under the License. @rem limitations under the License.
@rem @rem
@rem SPDX-License-Identifier: Apache-2.0
@rem
@if "%DEBUG%"=="" @echo off @if "%DEBUG%"=="" @echo off
@rem ########################################################################## @rem ##########################################################################
@@ -43,11 +45,11 @@ set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1 %JAVA_EXE% -version >NUL 2>&1
if %ERRORLEVEL% equ 0 goto execute if %ERRORLEVEL% equ 0 goto execute
echo. echo. 1>&2
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
echo. echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. echo location of your Java installation. 1>&2
goto fail goto fail
@@ -57,11 +59,11 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto execute if exist "%JAVA_EXE%" goto execute
echo. echo. 1>&2
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
echo. echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. echo location of your Java installation. 1>&2
goto fail goto fail

View File

@@ -1,3 +1,6 @@
pluginManagement { includeBuild("../node_modules/@react-native/gradle-plugin") }
plugins { id("com.facebook.react.settings") }
extensions.configure(com.facebook.react.ReactSettingsExtension){ ex -> ex.autolinkLibrariesFromCommand() }
rootProject.name = 'AwesomeProject' rootProject.name = 'AwesomeProject'
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings)
include ':app' include ':app'

Binary file not shown.

View File

@@ -7,6 +7,7 @@
objects = { objects = {
/* Begin PBXBuildFile section */ /* Begin PBXBuildFile section */
0C06D3B1D2C63EC04B024612 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 77A7A2D881E69AE3DCCE6BFE /* PrivacyInfo.xcprivacy */; };
0C80B921A6F3F58F76C31292 /* libPods-AwesomeProject.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-AwesomeProject.a */; }; 0C80B921A6F3F58F76C31292 /* libPods-AwesomeProject.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-AwesomeProject.a */; };
13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.mm */; }; 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.mm */; };
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
@@ -26,6 +27,7 @@
5709B34CF0A7D63546082F79 /* Pods-AwesomeProject.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject.release.xcconfig"; path = "Target Support Files/Pods-AwesomeProject/Pods-AwesomeProject.release.xcconfig"; sourceTree = "<group>"; }; 5709B34CF0A7D63546082F79 /* Pods-AwesomeProject.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject.release.xcconfig"; path = "Target Support Files/Pods-AwesomeProject/Pods-AwesomeProject.release.xcconfig"; sourceTree = "<group>"; };
5B7EB9410499542E8C5724F5 /* Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig"; path = "Target Support Files/Pods-AwesomeProject-AwesomeProjectTests/Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig"; sourceTree = "<group>"; }; 5B7EB9410499542E8C5724F5 /* Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig"; path = "Target Support Files/Pods-AwesomeProject-AwesomeProjectTests/Pods-AwesomeProject-AwesomeProjectTests.debug.xcconfig"; sourceTree = "<group>"; };
5DCACB8F33CDC322A6C60F78 /* libPods-AwesomeProject.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-AwesomeProject.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 5DCACB8F33CDC322A6C60F78 /* libPods-AwesomeProject.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-AwesomeProject.a"; sourceTree = BUILT_PRODUCTS_DIR; };
77A7A2D881E69AE3DCCE6BFE /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; name = PrivacyInfo.xcprivacy; path = AwesomeProject/PrivacyInfo.xcprivacy; sourceTree = "<group>"; };
81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = AwesomeProject/LaunchScreen.storyboard; sourceTree = "<group>"; }; 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = AwesomeProject/LaunchScreen.storyboard; sourceTree = "<group>"; };
89C6BE57DB24E9ADA2F236DE /* Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig"; path = "Target Support Files/Pods-AwesomeProject-AwesomeProjectTests/Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig"; sourceTree = "<group>"; }; 89C6BE57DB24E9ADA2F236DE /* Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig"; path = "Target Support Files/Pods-AwesomeProject-AwesomeProjectTests/Pods-AwesomeProject-AwesomeProjectTests.release.xcconfig"; sourceTree = "<group>"; };
ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; };
@@ -52,6 +54,7 @@
13B07FB61A68108700A75B9A /* Info.plist */, 13B07FB61A68108700A75B9A /* Info.plist */,
81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */, 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */,
13B07FB71A68108700A75B9A /* main.m */, 13B07FB71A68108700A75B9A /* main.m */,
77A7A2D881E69AE3DCCE6BFE /* PrivacyInfo.xcprivacy */,
); );
name = AwesomeProject; name = AwesomeProject;
sourceTree = "<group>"; sourceTree = "<group>";
@@ -169,6 +172,7 @@
files = ( files = (
81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */, 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */,
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */, 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
0C06D3B1D2C63EC04B024612 /* PrivacyInfo.xcprivacy in Resources */,
); );
runOnlyForDeploymentPostprocessing = 0; runOnlyForDeploymentPostprocessing = 0;
}; };
@@ -336,7 +340,7 @@
buildSettings = { buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO; ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "c++17"; CLANG_CXX_LANGUAGE_STANDARD = "c++20";
CLANG_CXX_LIBRARY = "libc++"; CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES; CLANG_ENABLE_OBJC_ARC = YES;
@@ -400,15 +404,11 @@
"-DFOLLY_MOBILE=1", "-DFOLLY_MOBILE=1",
"-DFOLLY_USE_LIBCPP=1", "-DFOLLY_USE_LIBCPP=1",
); );
OTHER_LDFLAGS = ( OTHER_LDFLAGS = "$(inherited)";
"$(inherited)",
"-Wl",
"-ld_classic",
" ",
"-Wl -ld_classic ",
);
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
SDKROOT = iphoneos; SDKROOT = iphoneos;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = "$(inherited) DEBUG";
USE_HERMES = true;
}; };
name = Debug; name = Debug;
}; };
@@ -417,7 +417,7 @@
buildSettings = { buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO; ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES;
CLANG_CXX_LANGUAGE_STANDARD = "c++17"; CLANG_CXX_LANGUAGE_STANDARD = "c++20";
CLANG_CXX_LIBRARY = "libc++"; CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES; CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES; CLANG_ENABLE_OBJC_ARC = YES;
@@ -476,15 +476,10 @@
"-DFOLLY_MOBILE=1", "-DFOLLY_MOBILE=1",
"-DFOLLY_USE_LIBCPP=1", "-DFOLLY_USE_LIBCPP=1",
); );
OTHER_LDFLAGS = ( OTHER_LDFLAGS = "$(inherited)";
"$(inherited)",
"-Wl",
"-ld_classic",
" ",
"-Wl -ld_classic ",
);
REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native";
SDKROOT = iphoneos; SDKROOT = iphoneos;
USE_HERMES = true;
VALIDATE_PRODUCT = YES; VALIDATE_PRODUCT = YES;
}; };
name = Release; name = Release;

View File

@@ -15,13 +15,14 @@
return [super application:application didFinishLaunchingWithOptions:launchOptions]; return [super application:application didFinishLaunchingWithOptions:launchOptions];
} }
- (NSURL *)sourceURLForBridge:(RCTBridge *)bridge - (NSURL *)bundleURL
{ {
#if DEBUG #if DEBUG
return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index"]; // 原先DEBUG这里的写法不作修改(所以DEBUG模式下不可热更新)
#else return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index"];
return [RCTPushy bundleURL]; #else
#endif return [RCTPushy bundleURL]; // <-- 把这里非DEBUG的情况替换为热更新bundle
#endif
} }
@end @end

View File

@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>NSPrivacyAccessedAPITypes</key>
<array>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryFileTimestamp</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>C617.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategoryUserDefaults</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>CA92.1</string>
</array>
</dict>
<dict>
<key>NSPrivacyAccessedAPIType</key>
<string>NSPrivacyAccessedAPICategorySystemBootTime</string>
<key>NSPrivacyAccessedAPITypeReasons</key>
<array>
<string>35F9.1</string>
</array>
</dict>
</array>
<key>NSPrivacyCollectedDataTypes</key>
<array/>
<key>NSPrivacyTracking</key>
<false/>
</dict>
</plist>

View File

@@ -8,16 +8,6 @@ require Pod::Executable.execute_command('node', ['-p',
platform :ios, min_ios_version_supported platform :ios, min_ios_version_supported
prepare_react_native_project! prepare_react_native_project!
# If you are using a `react-native-flipper` your iOS build will fail when `NO_FLIPPER=1` is set.
# because `react-native-flipper` depends on (FlipperKit,...) that will be excluded
#
# To fix this you can also exclude `react-native-flipper` using a `react-native.config.js`
# ```js
# module.exports = {
# dependencies: {
# ...(process.env.NO_FLIPPER ? { 'react-native-flipper': { platforms: { ios: null } } } : {}),
# ```
flipper_config = FlipperConfiguration.disabled
linkage = ENV['USE_FRAMEWORKS'] linkage = ENV['USE_FRAMEWORKS']
if linkage != nil if linkage != nil
@@ -28,19 +18,8 @@ end
target 'AwesomeProject' do target 'AwesomeProject' do
config = use_native_modules! config = use_native_modules!
# Flags change depending on the env values.
flags = get_default_flags()
use_react_native!( use_react_native!(
:path => config[:reactNativePath], :path => config[:reactNativePath],
# Hermes is now enabled by default. Disable by setting this flag to false.
:hermes_enabled => flags[:hermes_enabled],
:fabric_enabled => flags[:fabric_enabled],
# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable the next line.
:flipper_configuration => flipper_config,
# An absolute path to your application root. # An absolute path to your application root.
:app_path => "#{Pod::Config.instance.installation_root}/.." :app_path => "#{Pod::Config.instance.installation_root}/.."
) )
@@ -50,8 +29,8 @@ target 'AwesomeProject' do
react_native_post_install( react_native_post_install(
installer, installer,
config[:reactNativePath], config[:reactNativePath],
:mac_catalyst_enabled => false :mac_catalyst_enabled => false,
# :ccache_enabled => true
) )
__apply_Xcode_12_5_M1_post_install_workaround(installer)
end end
end end

File diff suppressed because it is too large Load Diff

View File

@@ -14,27 +14,28 @@
"dev:harmony": "react-native bundle-harmony --dev" "dev:harmony": "react-native bundle-harmony --dev"
}, },
"dependencies": { "dependencies": {
"form-data": "^4.0.1",
"patch-package": "^8.0.0", "patch-package": "^8.0.0",
"postinstall-postinstall": "^2.1.0", "postinstall-postinstall": "^2.1.0",
"react": "18.3.1", "react": "18.3.1",
"react-native": "0.76.1", "react-native": "0.76.3",
"react-native-camera-kit": "^14.0.0-beta15", "react-native-camera-kit": "^14.1.0",
"react-native-paper": "^5.12.5", "react-native-paper": "^5.12.5",
"react-native-safe-area-context": "^4.11.1", "react-native-safe-area-context": "^4.14.0",
"react-native-update": "^10.15.1", "react-native-update": "^10.17.1",
"react-native-vector-icons": "^10.2.0" "react-native-vector-icons": "^10.2.0"
}, },
"devDependencies": { "devDependencies": {
"@babel/core": "^7.25.2", "@babel/core": "^7.26.0",
"@babel/preset-env": "^7.25.3", "@babel/preset-env": "^7.26.0",
"@babel/runtime": "^7.25.0", "@babel/runtime": "^7.26.0",
"@react-native-community/cli": "15.0.0-alpha.2", "@react-native-community/cli": "15.0.0-alpha.2",
"@react-native-community/cli-platform-android": "15.0.0-alpha.2", "@react-native-community/cli-platform-android": "15.0.0-alpha.2",
"@react-native-community/cli-platform-ios": "15.0.0-alpha.2", "@react-native-community/cli-platform-ios": "15.0.0-alpha.2",
"@react-native/babel-preset": "0.76.1", "@react-native/babel-preset": "0.76.3",
"@react-native/eslint-config": "0.76.1", "@react-native/eslint-config": "0.76.3",
"@react-native/metro-config": "0.76.1", "@react-native/metro-config": "0.76.3",
"@react-native/typescript-config": "0.76.1", "@react-native/typescript-config": "0.76.3",
"@types/react": "^18.2.6", "@types/react": "^18.2.6",
"@types/react-test-renderer": "^18.0.0", "@types/react-test-renderer": "^18.0.0",
"babel-jest": "^29.6.3", "babel-jest": "^29.6.3",
@@ -42,7 +43,7 @@
"jest": "^29.6.3", "jest": "^29.6.3",
"prettier": "2.8.8", "prettier": "2.8.8",
"react-test-renderer": "18.3.1", "react-test-renderer": "18.3.1",
"typescript": "5.0.4" "typescript": "5.7.2"
}, },
"engines": { "engines": {
"node": ">=16" "node": ">=16"

View File

@@ -1,7 +1,8 @@
/* eslint-disable react-native/no-inline-styles */ /* eslint-disable react-native/no-inline-styles */
/* eslint-disable react/react-in-jsx-scope */ /* eslint-disable react/react-in-jsx-scope */
import {useCallback, useMemo, useState} from 'react'; import {useState} from 'react';
import { import {
Alert,
ActivityIndicator, ActivityIndicator,
Modal, Modal,
TextInput, TextInput,
@@ -13,132 +14,127 @@ import {
TouchableOpacity, TouchableOpacity,
} from 'react-native'; } from 'react-native';
import {PushyModule} from 'react-native-update'; import {PushyModule} from 'react-native-update/src/core';
const Hash = '9D5CE6EBA420717BE7E7D308B11F8207681B066C951D68F3994D19828F342474'; const Hash = '9D5CE6EBA420717BE7E7D308B11F8207681B066C951D68F3994D19828F342474';
const UUID = '00000000-0000-0000-0000-000000000000'; const UUID = '00000000-0000-0000-0000-000000000000';
const DownloadUrl = const DownloadUrl =
'http://cos.pgyer.com/697913e94d7441f20c686e2b0996a1aa.apk?sign=7a8f11b1df82cba45c8ac30b1acec88c&t=1680404102&response-content-disposition=attachment%3Bfilename%3DtestHotupdate_1.0.apk'; 'http://cos.pgyer.com/697913e94d7441f20c686e2b0996a1aa.apk?sign=7a8f11b1df82cba45c8ac30b1acec88c&t=1680404102&response-content-disposition=attachment%3Bfilename%3DtestHotupdate_1.0.apk';
const CustomDialog = ({title, visible, onConfirm}) => { export default function TestConsole({visible, onClose}) {
if (!visible) {
return null;
}
return (
<View style={styles.overlay}>
<View style={styles.dialog}>
<Text style={styles.title}>{title}</Text>
<TouchableOpacity
testID="done"
style={styles.button}
onLongPress={onConfirm}>
<Text style={styles.buttonText}>确认</Text>
</TouchableOpacity>
</View>
</View>
);
};
export default function TestConsole({visible}) {
const [text, setText] = useState(''); const [text, setText] = useState('');
const [running, setRunning] = useState(false); const [running, setRunning] = useState(false);
const [options, setOptions] = useState(); const convertCommands = (cmd, params) => {
const [alertVisible, setAlertVisible] = useState(false); if (typeof params === 'string') {
const [alertMsg, setAlertMsg] = useState(''); return `${cmd}\n${params}`;
const NativeTestMethod = useMemo(() => { }
return [ let paramText = '';
for (const [k, v] of Object.entries(params)) {
paramText += `\n${k}\n${v}`;
}
return `${cmd}${paramText}`;
};
const shortCuts = [
{ {
name: 'setLocalHashInfo', name: 'setLocalHashInfo',
invoke: () => { invoke: () => {
setText( setText(
`setLocalHashInfo\n${Hash}\n{\"version\":\"1.0.0\",\"size\":\"19M\"}`, convertCommands('setLocalHashInfo', {
version: '1.0.0',
size: '19M',
}),
); );
}, },
}, },
{ {
name: 'getLocalHashInfo', name: 'getLocalHashInfo',
invoke: () => { invoke: () => {
setText(`getLocalHashInfo\n${Hash}`); setText(convertCommands('getLocalHashInfo', Hash));
}, },
}, },
{ {
name: 'setUuid', name: 'setUuid',
invoke: () => { invoke: () => {
setText(`setUuid\n${UUID}`); setText(convertCommands('setUuid', UUID));
}, },
}, },
{ {
name: 'reloadUpdate', name: 'reloadUpdate',
invoke: () => { invoke: () => {
setText('reloadUpdate'); setText(convertCommands('reloadUpdate', {hash: Hash}));
setOptions({hash: Hash});
}, },
}, },
{ {
name: 'setNeedUpdate', name: 'setNeedUpdate',
invoke: () => { invoke: () => {
setText('setNeedUpdate'); setText(convertCommands('setNeedUpdate', {hash: Hash}));
setOptions({hash: Hash});
}, },
}, },
{ {
name: 'markSuccess', name: 'markSuccess',
invoke: () => { invoke: () => {
setText('markSuccess'); setText(convertCommands('markSuccess'));
setOptions(undefined);
}, },
}, },
{ {
name: 'downloadPatchFromPpk', name: 'downloadPatchFromPpk',
invoke: () => { invoke: () => {
setText('downloadPatchFromPpk'); setText(
setOptions({updateUrl: DownloadUrl, hash: Hash, originHash: Hash}); convertCommands('downloadPatchFromPpk', {
updateUrl: DownloadUrl,
hash: Hash,
originHash: Hash,
}),
);
}, },
}, },
{ {
name: 'downloadPatchFromPackage', name: 'downloadPatchFromPackage',
invoke: () => { invoke: () => {
setText('downloadPatchFromPackage'); setText(
setOptions({updateUrl: DownloadUrl, hash: Hash}); convertCommands('downloadPatchFromPackage', {
updateUrl: DownloadUrl,
hash: Hash,
}),
);
}, },
}, },
{ {
name: 'downloadFullUpdate', name: 'downloadFullUpdate',
invoke: () => { invoke: () => {
setText('downloadFullUpdate'); setText(
setOptions({updateUrl: DownloadUrl, hash: Hash}); convertCommands('downloadFullUpdate', {
updateUrl: DownloadUrl,
hash: Hash,
}),
);
}, },
}, },
{ {
name: 'downloadAndInstallApk', name: 'downloadAndInstallApk',
invoke: () => { invoke: () => {
setText('downloadAndInstallApk'); setText(
setOptions({url: DownloadUrl, target: Hash, hash: Hash}); convertCommands('downloadAndInstallApk', {
url: DownloadUrl,
target: Hash,
hash: Hash,
}),
);
}, },
}, },
]; ];
}, []);
const renderTestView = useCallback(() => {
const views = [];
for (let i = 0; i < NativeTestMethod.length; i++) {
views.push(
<TouchableOpacity
key={i}
testID={NativeTestMethod[i].name}
onLongPress={() => {
NativeTestMethod[i].invoke();
}}>
<Text>{NativeTestMethod[i].name}</Text>
</TouchableOpacity>,
);
}
return <View>{views}</View>;
}, [NativeTestMethod]);
return ( return (
<Modal visible={visible}> <Modal visible={visible}>
<SafeAreaView style={{flex: 1, padding: 10}}> <SafeAreaView style={{flex: 1, padding: 10}}>
<Text>调试Pushy方法方法名参数值换行</Text> <View
style={{
flexDirection: 'row',
justifyContent: 'space-between',
alignItems: 'center',
}}>
<Text>调试Pushy方法方法名参数值换行</Text>
<Button title="Close" onPress={onClose} />
</View>
<TextInput <TextInput
autoCorrect={false} autoCorrect={false}
autoCapitalize="none" autoCapitalize="none"
@@ -167,46 +163,49 @@ export default function TestConsole({visible}) {
marginBottom: 5, marginBottom: 5,
}} }}
testID="submit" testID="submit"
onLongPress={async () => { onPress={async () => {
setRunning(true); setRunning(true);
try { try {
const inputs = text.split('\n'); const inputs = text.split('\n');
const methodName = inputs[0]; const methodName = inputs[0];
let params = []; let params;
if (inputs.length === 1) { if (inputs.length === 1) {
if (options) { await PushyModule[methodName]();
await PushyModule[methodName](options);
} else {
await PushyModule[methodName]();
}
} else { } else {
if (inputs.length === 2) { if (inputs.length === 2) {
params = [inputs[1]]; params = inputs[1];
} else { } else {
params = [inputs[1], inputs[2]]; params = {};
for (let i = 1; i < inputs.length; i += 2) {
params[inputs[i]] = inputs[i + 1];
}
console.log({inputs, params}); console.log({inputs, params});
} }
await PushyModule[methodName](...params); await PushyModule[methodName](params);
} }
setAlertVisible(true); Alert.alert('done');
setAlertMsg('done');
} catch (e) { } catch (e) {
setAlertVisible(true); Alert.alert(e.message);
setAlertMsg(e.message);
} }
setRunning(false); setRunning(false);
}}> }}>
<Text style={{color: 'white'}}>执行</Text> <Text style={{color: 'white'}}>执行</Text>
</TouchableOpacity> </TouchableOpacity>
<Button title="重置" onPress={() => setText('')} /> <Button title="重置" onPress={() => setText('')} />
{renderTestView()} {
<CustomDialog <View>
title={alertMsg} {shortCuts.map(({name, invoke}, i) => (
visible={alertVisible} <TouchableOpacity
onConfirm={() => { key={i}
setAlertVisible(false); testID={name}
}} onPress={() => {
/> invoke();
}}>
<Text>{name}</Text>
</TouchableOpacity>
))}
</View>
}
</SafeAreaView> </SafeAreaView>
</Modal> </Modal>
); );

View File

@@ -124,7 +124,10 @@ function App() {
react-native-update版本{client?.version} react-native-update版本{client?.version}
</Text> </Text>
</TouchableOpacity> </TouchableOpacity>
<TestConsole visible={showTestConsole} /> <TestConsole
visible={showTestConsole}
onClose={() => setShowTestConsole(false)}
/>
{snackbarVisible && ( {snackbarVisible && (
<Snackbar <Snackbar
visible={snackbarVisible} visible={snackbarVisible}

View File

@@ -1,6 +1,6 @@
# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1 # yarn lockfile v1
# bun ./bun.lockb --hash: 67E2692C492EC786-b10e704281ba7457-49AF9307B9B1790A-9c4b6a5068634c09 # bun ./bun.lockb --hash: 2547959BF9110937-8e976afc6d697d5e-F1358D41009E1D4A-b33074d79ffc31a0
"@ampproject/remapping@^2.2.0": "@ampproject/remapping@^2.2.0":
@@ -25,7 +25,7 @@
resolved "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.26.2.tgz" resolved "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.26.2.tgz"
integrity sha512-Z0WgzSEa+aUcdiJuCIqgujCshpMWgUpgOxXotrYPSA53hA3qopNaqcJpyr0hVb1FeWdnqFA35/fUtXgBK8srQg== integrity sha512-Z0WgzSEa+aUcdiJuCIqgujCshpMWgUpgOxXotrYPSA53hA3qopNaqcJpyr0hVb1FeWdnqFA35/fUtXgBK8srQg==
"@babel/core@^7.0.0", "@babel/core@^7.0.0-0", "@babel/core@^7.0.0-0 || ^8.0.0-0 <8.0.0", "@babel/core@^7.11.0", "@babel/core@^7.11.6", "@babel/core@^7.12.0", "@babel/core@^7.12.3", "@babel/core@^7.13.0", "@babel/core@^7.13.16", "@babel/core@^7.23.9", "@babel/core@^7.25.2", "@babel/core@^7.4.0 || ^8.0.0-0 <8.0.0", "@babel/core@^7.8.0": "@babel/core@^7.0.0", "@babel/core@^7.0.0-0", "@babel/core@^7.0.0-0 || ^8.0.0-0 <8.0.0", "@babel/core@^7.11.0", "@babel/core@^7.11.6", "@babel/core@^7.12.0", "@babel/core@^7.12.3", "@babel/core@^7.13.0", "@babel/core@^7.13.16", "@babel/core@^7.23.9", "@babel/core@^7.25.2", "@babel/core@^7.26.0", "@babel/core@^7.4.0 || ^8.0.0-0 <8.0.0", "@babel/core@^7.8.0":
version "7.26.0" version "7.26.0"
resolved "https://registry.npmjs.org/@babel/core/-/core-7.26.0.tgz" resolved "https://registry.npmjs.org/@babel/core/-/core-7.26.0.tgz"
integrity sha512-i1SLeK+DzNnQ3LL/CswPCa/E5u4lh1k6IAEphON8F+cXt0t9euTshDru0q7/IqMa1PMPz5RnHuHscF8/ZJsStg== integrity sha512-i1SLeK+DzNnQ3LL/CswPCa/E5u4lh1k6IAEphON8F+cXt0t9euTshDru0q7/IqMa1PMPz5RnHuHscF8/ZJsStg==
@@ -918,7 +918,7 @@
"@babel/helper-plugin-utils" "^7.25.9" "@babel/helper-plugin-utils" "^7.25.9"
"@babel/helper-create-regexp-features-plugin" "^7.25.9" "@babel/helper-create-regexp-features-plugin" "^7.25.9"
"@babel/preset-env@^7.1.6", "@babel/preset-env@^7.25.3": "@babel/preset-env@^7.1.6", "@babel/preset-env@^7.26.0":
version "7.26.0" version "7.26.0"
resolved "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.26.0.tgz" resolved "https://registry.npmjs.org/@babel/preset-env/-/preset-env-7.26.0.tgz"
integrity sha512-H84Fxq0CQJNdPFT2DrfnylZ3cf5K43rGfWK4LJGPpjKHiZlk0/RzwEus3PDDZZg+/Er7lCA03MVacueUuXdzfw== integrity sha512-H84Fxq0CQJNdPFT2DrfnylZ3cf5K43rGfWK4LJGPpjKHiZlk0/RzwEus3PDDZZg+/Er7lCA03MVacueUuXdzfw==
@@ -1033,7 +1033,7 @@
find-cache-dir "^2.0.0" find-cache-dir "^2.0.0"
source-map-support "^0.5.16" source-map-support "^0.5.16"
"@babel/runtime@^7.25.0", "@babel/runtime@^7.8.4": "@babel/runtime@^7.25.0", "@babel/runtime@^7.26.0", "@babel/runtime@^7.8.4":
version "7.26.0" version "7.26.0"
resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.26.0.tgz" resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.26.0.tgz"
integrity sha512-FDSOghenHTiToteC/QRlv2q3DhPZ/oOXTBoirfWNx1Cx3TMVcGWQtMMmQcSvb/JjpNeGzx8Pq/b4fKEJuWm1sw== integrity sha512-FDSOghenHTiToteC/QRlv2q3DhPZ/oOXTBoirfWNx1Cx3TMVcGWQtMMmQcSvb/JjpNeGzx8Pq/b4fKEJuWm1sw==
@@ -1592,6 +1592,11 @@
resolved "https://registry.npmjs.org/@react-native/assets-registry/-/assets-registry-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/assets-registry/-/assets-registry-0.76.1.tgz"
integrity sha512-1mcDjyvC4Z+XYtY+Abl6pW9P49l/9HJmRChX7EHF1SoXe7zPAPBoAqeZsJNtf8dhJR3u/eGvapr1yJq8T/psEg== integrity sha512-1mcDjyvC4Z+XYtY+Abl6pW9P49l/9HJmRChX7EHF1SoXe7zPAPBoAqeZsJNtf8dhJR3u/eGvapr1yJq8T/psEg==
"@react-native/assets-registry@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/assets-registry/-/assets-registry-0.76.3.tgz"
integrity sha512-7Fnc3lzCFFpnoyL1egua6d/qUp0KiIpeSLbfOMln4nI2g2BMzyFHdPjJnpLV2NehmS0omOOkrfRqK5u1F/MXzA==
"@react-native/babel-plugin-codegen@0.76.1": "@react-native/babel-plugin-codegen@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.76.1.tgz"
@@ -1599,6 +1604,13 @@
dependencies: dependencies:
"@react-native/codegen" "0.76.1" "@react-native/codegen" "0.76.1"
"@react-native/babel-plugin-codegen@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/babel-plugin-codegen/-/babel-plugin-codegen-0.76.3.tgz"
integrity sha512-mZ7jmIIg4bUnxCqY3yTOkoHvvzsDyrZgfnIKiTGm5QACrsIGa5eT3pMFpMm2OpxGXRDrTMsYdPXE2rCyDX52VQ==
dependencies:
"@react-native/codegen" "0.76.3"
"@react-native/babel-preset@0.76.1": "@react-native/babel-preset@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/babel-preset/-/babel-preset-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/babel-preset/-/babel-preset-0.76.1.tgz"
@@ -1650,6 +1662,57 @@
"@babel/plugin-transform-logical-assignment-operators" "^7.24.7" "@babel/plugin-transform-logical-assignment-operators" "^7.24.7"
"@babel/plugin-transform-named-capturing-groups-regex" "^7.24.7" "@babel/plugin-transform-named-capturing-groups-regex" "^7.24.7"
"@react-native/babel-preset@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/babel-preset/-/babel-preset-0.76.3.tgz"
integrity sha512-zi2nPlQf9q2fmfPyzwWEj6DU96v8ziWtEfG7CTAX2PG/Vjfsr94vn/wWrCdhBVvLRQ6Kvd/MFAuDYpxmQwIiVQ==
dependencies:
"@babel/core" "^7.25.2"
react-refresh "^0.14.0"
"@babel/template" "^7.25.0"
"@babel/plugin-transform-for-of" "^7.24.7"
"@babel/plugin-transform-spread" "^7.24.7"
"@babel/plugin-transform-classes" "^7.25.4"
"@babel/plugin-transform-runtime" "^7.24.7"
"@babel/plugin-transform-literals" "^7.25.2"
"@babel/plugin-transform-react-jsx" "^7.25.2"
babel-plugin-syntax-hermes-parser "^0.25.1"
babel-plugin-transform-flow-enums "^0.0.2"
"@babel/plugin-transform-parameters" "^7.24.7"
"@babel/plugin-transform-typescript" "^7.25.2"
"@react-native/babel-plugin-codegen" "0.76.3"
"@babel/plugin-syntax-dynamic-import" "^7.8.3"
"@babel/plugin-transform-regenerator" "^7.24.7"
"@babel/plugin-transform-sticky-regex" "^7.24.7"
"@babel/plugin-transform-block-scoping" "^7.25.0"
"@babel/plugin-transform-destructuring" "^7.24.8"
"@babel/plugin-transform-function-name" "^7.25.1"
"@babel/plugin-transform-unicode-regex" "^7.24.7"
"@babel/plugin-syntax-optional-chaining" "^7.8.3"
"@babel/plugin-transform-react-jsx-self" "^7.24.7"
"@babel/plugin-transform-arrow-functions" "^7.24.7"
"@babel/plugin-transform-private-methods" "^7.24.7"
"@babel/plugin-syntax-export-default-from" "^7.24.7"
"@babel/plugin-transform-class-properties" "^7.25.4"
"@babel/plugin-transform-flow-strip-types" "^7.25.2"
"@babel/plugin-transform-modules-commonjs" "^7.24.8"
"@babel/plugin-transform-react-jsx-source" "^7.24.7"
"@babel/plugin-transform-numeric-separator" "^7.24.7"
"@babel/plugin-transform-optional-chaining" "^7.24.8"
"@babel/plugin-proposal-export-default-from" "^7.24.7"
"@babel/plugin-transform-async-to-generator" "^7.24.7"
"@babel/plugin-transform-object-rest-spread" "^7.24.7"
"@babel/plugin-transform-react-display-name" "^7.24.7"
"@babel/plugin-transform-computed-properties" "^7.24.7"
"@babel/plugin-transform-shorthand-properties" "^7.24.7"
"@babel/plugin-transform-optional-catch-binding" "^7.24.7"
"@babel/plugin-syntax-nullish-coalescing-operator" "^7.8.3"
"@babel/plugin-transform-async-generator-functions" "^7.25.4"
"@babel/plugin-transform-private-property-in-object" "^7.24.7"
"@babel/plugin-transform-nullish-coalescing-operator" "^7.24.7"
"@babel/plugin-transform-logical-assignment-operators" "^7.24.7"
"@babel/plugin-transform-named-capturing-groups-regex" "^7.24.7"
"@react-native/codegen@0.76.1": "@react-native/codegen@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/codegen/-/codegen-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/codegen/-/codegen-0.76.1.tgz"
@@ -1664,6 +1727,20 @@
"@babel/parser" "^7.25.3" "@babel/parser" "^7.25.3"
hermes-parser "0.23.1" hermes-parser "0.23.1"
"@react-native/codegen@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/codegen/-/codegen-0.76.3.tgz"
integrity sha512-oJCH/jbYeGmFJql8/y76gqWCCd74pyug41yzYAjREso1Z7xL88JhDyKMvxEnfhSdMOZYVl479N80xFiXPy3ZYA==
dependencies:
glob "^7.1.1"
yargs "^17.6.2"
mkdirp "^0.5.1"
invariant "^2.2.4"
nullthrows "^1.1.1"
jscodeshift "^0.14.0"
"@babel/parser" "^7.25.3"
hermes-parser "0.23.1"
"@react-native/community-cli-plugin@0.76.1": "@react-native/community-cli-plugin@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/community-cli-plugin/-/community-cli-plugin-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/community-cli-plugin/-/community-cli-plugin-0.76.1.tgz"
@@ -1680,11 +1757,33 @@
"@react-native/dev-middleware" "0.76.1" "@react-native/dev-middleware" "0.76.1"
"@react-native/metro-babel-transformer" "0.76.1" "@react-native/metro-babel-transformer" "0.76.1"
"@react-native/community-cli-plugin@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/community-cli-plugin/-/community-cli-plugin-0.76.3.tgz"
integrity sha512-vgsLixHS24jR0d0QqPykBWFaC+V8x9cM3cs4oYXw3W199jgBNGP9MWcUJLazD2vzrT/lUTVBVg0rBeB+4XR6fg==
dependencies:
chalk "^4.0.0"
execa "^5.1.1"
metro "^0.81.0"
semver "^7.1.3"
readline "^1.3.0"
invariant "^2.2.4"
metro-core "^0.81.0"
node-fetch "^2.2.0"
metro-config "^0.81.0"
"@react-native/dev-middleware" "0.76.3"
"@react-native/metro-babel-transformer" "0.76.3"
"@react-native/debugger-frontend@0.76.1": "@react-native/debugger-frontend@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/debugger-frontend/-/debugger-frontend-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/debugger-frontend/-/debugger-frontend-0.76.1.tgz"
integrity sha512-0gExx7GR8o2ctGfjIZ9+x54iFbg0eP6+kMYzRA6AcgmFAmMGLADMmjtObCN0CqGeZyWtdVVqcv5mAwRwmMlNWA== integrity sha512-0gExx7GR8o2ctGfjIZ9+x54iFbg0eP6+kMYzRA6AcgmFAmMGLADMmjtObCN0CqGeZyWtdVVqcv5mAwRwmMlNWA==
"@react-native/debugger-frontend@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/debugger-frontend/-/debugger-frontend-0.76.3.tgz"
integrity sha512-pMHQ3NpPB28RxXciSvm2yD+uDx3pkhzfuWkc7VFgOduyzPSIr0zotUiOJzsAtrj8++bPbOsAraCeQhCqoOTWQw==
"@react-native/dev-middleware@0.76.1": "@react-native/dev-middleware@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/dev-middleware/-/dev-middleware-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/dev-middleware/-/dev-middleware-0.76.1.tgz"
@@ -1702,10 +1801,27 @@
chromium-edge-launcher "^0.2.0" chromium-edge-launcher "^0.2.0"
"@react-native/debugger-frontend" "0.76.1" "@react-native/debugger-frontend" "0.76.1"
"@react-native/eslint-config@0.76.1": "@react-native/dev-middleware@0.76.3":
version "0.76.1" version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/eslint-config/-/eslint-config-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/dev-middleware/-/dev-middleware-0.76.3.tgz"
integrity sha512-YaiE/eoEzw3Ax1UCk5TT6YFnQN927SvTxOk9kV0FQPxR862C9WSVMhzbuwNwgAkkItxzo2qrARx9sdibcCqiyA== integrity sha512-b+2IpW40z1/S5Jo5JKrWPmucYU/PzeGyGBZZ/SJvmRnBDaP3txb9yIqNZAII1EWsKNhedh8vyRO5PSuJ9Juqzw==
dependencies:
ws "^6.2.3"
open "^7.0.3"
debug "^2.2.0"
connect "^3.6.5"
nullthrows "^1.1.1"
selfsigned "^2.4.1"
serve-static "^1.13.1"
chrome-launcher "^0.15.2"
"@isaacs/ttlcache" "^1.4.1"
chromium-edge-launcher "^0.2.0"
"@react-native/debugger-frontend" "0.76.3"
"@react-native/eslint-config@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/eslint-config/-/eslint-config-0.76.3.tgz"
integrity sha512-TmZ1M6Aw1vnhB9LA0zFx7yq/lQYSWNPpq5fS1jFzz99XemFB92lI9vhqzwRun1VmztTs4Cv1kcJa51xYFRPh2w==
dependencies: dependencies:
"@babel/core" "^7.25.2" "@babel/core" "^7.25.2"
hermes-eslint "^0.23.1" hermes-eslint "^0.23.1"
@@ -1717,25 +1833,35 @@
"@typescript-eslint/parser" "^7.1.1" "@typescript-eslint/parser" "^7.1.1"
eslint-plugin-react-hooks "^4.6.0" eslint-plugin-react-hooks "^4.6.0"
eslint-plugin-react-native "^4.0.0" eslint-plugin-react-native "^4.0.0"
"@react-native/eslint-plugin" "0.76.1" "@react-native/eslint-plugin" "0.76.3"
eslint-plugin-eslint-comments "^3.2.0" eslint-plugin-eslint-comments "^3.2.0"
"@typescript-eslint/eslint-plugin" "^7.1.1" "@typescript-eslint/eslint-plugin" "^7.1.1"
"@react-native/eslint-plugin@0.76.1": "@react-native/eslint-plugin@0.76.3":
version "0.76.1" version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/eslint-plugin/-/eslint-plugin-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/eslint-plugin/-/eslint-plugin-0.76.3.tgz"
integrity sha512-Sw/WTuV9RVQQ7g+p1wt65g0UCdtd2w0g3eQ6HaYIc3u3HrTXkO9cGXsgd98yV6jjQtXSB/EGnDOajC9y3OmDOw== integrity sha512-aHs61SGO61K/ULI6jUjrIajeYAz3thh0VT2r/cFsgOxeXgr8j98mqr6+beGlHo4BET0TC7u6+p+fxQNGoI9blg==
"@react-native/gradle-plugin@0.76.1": "@react-native/gradle-plugin@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/gradle-plugin/-/gradle-plugin-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/gradle-plugin/-/gradle-plugin-0.76.1.tgz"
integrity sha512-X7rNFltPa9QYxvYrQGaSCw7U57C+y+DwspXf4AnLZj0bQm9tL6UYpijh5vE3VmPcHn76/RNU2bpFjVvWg6gjqw== integrity sha512-X7rNFltPa9QYxvYrQGaSCw7U57C+y+DwspXf4AnLZj0bQm9tL6UYpijh5vE3VmPcHn76/RNU2bpFjVvWg6gjqw==
"@react-native/gradle-plugin@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/gradle-plugin/-/gradle-plugin-0.76.3.tgz"
integrity sha512-t0aYZ8ND7+yc+yIm6Yp52bInneYpki6RSIFZ9/LMUzgMKvEB62ptt/7sfho9QkKHCNxE1DJSWIqLIGi/iHHkyg==
"@react-native/js-polyfills@0.76.1": "@react-native/js-polyfills@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/js-polyfills/-/js-polyfills-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/js-polyfills/-/js-polyfills-0.76.1.tgz"
integrity sha512-HO3fzJ0FnrnQGmxdXxh2lcGGAMfaX9h1Pg1Zh38MkVw35/KnZHxHqxg6cruze6iWwZdfqSoIcQoalmMuAHby7Q== integrity sha512-HO3fzJ0FnrnQGmxdXxh2lcGGAMfaX9h1Pg1Zh38MkVw35/KnZHxHqxg6cruze6iWwZdfqSoIcQoalmMuAHby7Q==
"@react-native/js-polyfills@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/js-polyfills/-/js-polyfills-0.76.3.tgz"
integrity sha512-pubJFArMMrdZiytH+W95KngcSQs+LsxOBsVHkwgMnpBfRUxXPMK4fudtBwWvhnwN76Oe+WhxSq7vOS5XgoPhmw==
"@react-native/metro-babel-transformer@0.76.1": "@react-native/metro-babel-transformer@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.76.1.tgz"
@@ -1746,25 +1872,40 @@
hermes-parser "0.23.1" hermes-parser "0.23.1"
"@react-native/babel-preset" "0.76.1" "@react-native/babel-preset" "0.76.1"
"@react-native/metro-config@0.76.1": "@react-native/metro-babel-transformer@0.76.3":
version "0.76.1" version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/metro-config/-/metro-config-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/metro-babel-transformer/-/metro-babel-transformer-0.76.3.tgz"
integrity sha512-RvsflPKsQ1tEaHDJksnMWwW5wtv8fskMRviL/jHlEW/ULEQ/MOE2yjuvJlRQkNvfqlJjkc1mczjy4+RO3mDQ6g== integrity sha512-b2zQPXmW7avw/7zewc9nzMULPIAjsTwN03hskhxHUJH5pzUf7pIklB3FrgYPZrRhJgzHiNl3tOPu7vqiKzBYPg==
dependencies:
nullthrows "^1.1.1"
"@babel/core" "^7.25.2"
hermes-parser "0.23.1"
"@react-native/babel-preset" "0.76.3"
"@react-native/metro-config@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/metro-config/-/metro-config-0.76.3.tgz"
integrity sha512-rRaFZAflH/OcH+rveH+hn2BUSLnfb0tXHyBY7xX+fF2dmxnWh7HiRD2npG36z079Kq3ApykUbxdCtpy8n+GlLw==
dependencies: dependencies:
metro-config "^0.81.0" metro-config "^0.81.0"
metro-runtime "^0.81.0" metro-runtime "^0.81.0"
"@react-native/js-polyfills" "0.76.1" "@react-native/js-polyfills" "0.76.3"
"@react-native/metro-babel-transformer" "0.76.1" "@react-native/metro-babel-transformer" "0.76.3"
"@react-native/normalize-colors@0.76.1": "@react-native/normalize-colors@0.76.1":
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/@react-native/normalize-colors/-/normalize-colors-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/normalize-colors/-/normalize-colors-0.76.1.tgz"
integrity sha512-/+CUk/wGWIdXbJYVLw/q6Fs8Z0x91zzfXIbNiZUdSW1TNEDmytkF371H8a1/Nx3nWa1RqCMVsaZHCG4zqxeDvg== integrity sha512-/+CUk/wGWIdXbJYVLw/q6Fs8Z0x91zzfXIbNiZUdSW1TNEDmytkF371H8a1/Nx3nWa1RqCMVsaZHCG4zqxeDvg==
"@react-native/typescript-config@0.76.1": "@react-native/normalize-colors@0.76.3":
version "0.76.1" version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/typescript-config/-/typescript-config-0.76.1.tgz" resolved "https://registry.npmjs.org/@react-native/normalize-colors/-/normalize-colors-0.76.3.tgz"
integrity sha512-KcmgsFG/c3WdAqy7/06Zvfkye3XIc/0zItlFMSGMgAjFFuCTomXqpmJdrtTBheCDy+gbKaR/vWf+snL8C+OVvA== integrity sha512-Yrpmrh4IDEupUUM/dqVxhAN8QW1VEUR3Qrk2lzJC1jB2s46hDe0hrMP2vs12YJqlzshteOthjwXQlY0TgIzgbg==
"@react-native/typescript-config@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/typescript-config/-/typescript-config-0.76.3.tgz"
integrity sha512-7R4b3jB+0JXVOV5nQHZF6HwO3Dhy2EvOne+gPPrjxjfhy0o7453xKq/oGrmuy7tKlCJXf9A4YRvcCHucLRZA/w==
"@react-native/virtualized-lists@0.76.1": "@react-native/virtualized-lists@0.76.1":
version "0.76.1" version "0.76.1"
@@ -1774,6 +1915,14 @@
invariant "^2.2.4" invariant "^2.2.4"
nullthrows "^1.1.1" nullthrows "^1.1.1"
"@react-native/virtualized-lists@0.76.3":
version "0.76.3"
resolved "https://registry.npmjs.org/@react-native/virtualized-lists/-/virtualized-lists-0.76.3.tgz"
integrity sha512-wTGv9pVh3vAOWb29xFm+J9VRe9dUcUcb9FyaMLT/Hxa88W4wqa5ZMe1V9UvrrBiA1G5DKjv8/1ZcDsJhyugVKA==
dependencies:
invariant "^2.2.4"
nullthrows "^1.1.1"
"@sideway/address@^4.1.5": "@sideway/address@^4.1.5":
version "4.1.5" version "4.1.5"
resolved "https://registry.npmjs.org/@sideway/address/-/address-4.1.5.tgz" resolved "https://registry.npmjs.org/@sideway/address/-/address-4.1.5.tgz"
@@ -2290,6 +2439,11 @@ async-limiter@~1.0.0:
resolved "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz" resolved "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz"
integrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ== integrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==
asynckit@^0.4.0:
version "0.4.0"
resolved "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz"
integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==
at-least-node@^1.0.0: at-least-node@^1.0.0:
version "1.0.0" version "1.0.0"
resolved "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz" resolved "https://registry.npmjs.org/at-least-node/-/at-least-node-1.0.0.tgz"
@@ -2372,6 +2526,13 @@ babel-plugin-syntax-hermes-parser@^0.23.1:
dependencies: dependencies:
hermes-parser "0.23.1" hermes-parser "0.23.1"
babel-plugin-syntax-hermes-parser@^0.25.1:
version "0.25.1"
resolved "https://registry.npmjs.org/babel-plugin-syntax-hermes-parser/-/babel-plugin-syntax-hermes-parser-0.25.1.tgz"
integrity sha512-IVNpGzboFLfXZUAwkLFcI/bnqVbwky0jP3eBno4HKtqvQJAHBLdgxiG6lQ4to0+Q/YCN3PO0od5NZwIKyY4REQ==
dependencies:
hermes-parser "0.25.1"
babel-plugin-transform-flow-enums@^0.0.2: babel-plugin-transform-flow-enums@^0.0.2:
version "0.0.2" version "0.0.2"
resolved "https://registry.npmjs.org/babel-plugin-transform-flow-enums/-/babel-plugin-transform-flow-enums-0.0.2.tgz" resolved "https://registry.npmjs.org/babel-plugin-transform-flow-enums/-/babel-plugin-transform-flow-enums-0.0.2.tgz"
@@ -2692,6 +2853,13 @@ colorette@^1.0.7:
resolved "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz" resolved "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz"
integrity sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g== integrity sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==
combined-stream@^1.0.8:
version "1.0.8"
resolved "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz"
integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==
dependencies:
delayed-stream "~1.0.0"
command-exists@^1.2.8: command-exists@^1.2.8:
version "1.2.9" version "1.2.9"
resolved "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz" resolved "https://registry.npmjs.org/command-exists/-/command-exists-1.2.9.tgz"
@@ -2912,6 +3080,11 @@ define-properties@^1.1.3, define-properties@^1.2.0, define-properties@^1.2.1:
has-property-descriptors "^1.0.0" has-property-descriptors "^1.0.0"
object-keys "^1.1.1" object-keys "^1.1.1"
delayed-stream@~1.0.0:
version "1.0.0"
resolved "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz"
integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==
denodeify@^1.2.1: denodeify@^1.2.1:
version "1.2.1" version "1.2.1"
resolved "https://registry.npmjs.org/denodeify/-/denodeify-1.2.1.tgz" resolved "https://registry.npmjs.org/denodeify/-/denodeify-1.2.1.tgz"
@@ -3534,6 +3707,15 @@ for-each@^0.3.3:
dependencies: dependencies:
is-callable "^1.1.3" is-callable "^1.1.3"
form-data@^4.0.1:
version "4.0.1"
resolved "https://registry.npmjs.org/form-data/-/form-data-4.0.1.tgz"
integrity sha512-tzN8e4TX8+kkxGPK8D5u0FNmjPUjw3lwC9lSLxxoB/+GtsJG91CO8bSWy73APlgAZzZbXEYZJuxjkHH2w+Ezhw==
dependencies:
asynckit "^0.4.0"
combined-stream "^1.0.8"
mime-types "^2.1.12"
fresh@0.5.2: fresh@0.5.2:
version "0.5.2" version "0.5.2"
resolved "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz" resolved "https://registry.npmjs.org/fresh/-/fresh-0.5.2.tgz"
@@ -3763,6 +3945,11 @@ hermes-estree@0.24.0:
resolved "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.24.0.tgz" resolved "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.24.0.tgz"
integrity sha512-LyoXLB7IFzeZW0EvAbGZacbxBN7t6KKSDqFJPo3Ydow7wDlrDjXwsdiAHV6XOdvEN9MEuWXsSIFN4tzpyrXIHw== integrity sha512-LyoXLB7IFzeZW0EvAbGZacbxBN7t6KKSDqFJPo3Ydow7wDlrDjXwsdiAHV6XOdvEN9MEuWXsSIFN4tzpyrXIHw==
hermes-estree@0.25.1:
version "0.25.1"
resolved "https://registry.npmjs.org/hermes-estree/-/hermes-estree-0.25.1.tgz"
integrity sha512-0wUoCcLp+5Ev5pDW2OriHC2MJCbwLwuRx+gAqMTOkGKJJiBCLjtrvy4PWUGn6MIVefecRpzoOZ/UV6iGdOr+Cw==
hermes-parser@0.23.1: hermes-parser@0.23.1:
version "0.23.1" version "0.23.1"
resolved "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.23.1.tgz" resolved "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.23.1.tgz"
@@ -3777,6 +3964,13 @@ hermes-parser@0.24.0:
dependencies: dependencies:
hermes-estree "0.24.0" hermes-estree "0.24.0"
hermes-parser@0.25.1:
version "0.25.1"
resolved "https://registry.npmjs.org/hermes-parser/-/hermes-parser-0.25.1.tgz"
integrity sha512-6pEjquH3rqaI6cYAXYPcz9MS4rY6R4ngRgrgfDshRptUZIc3lw0MCIJIGDj9++mfySOuPTHB4nrSW99BCvOPIA==
dependencies:
hermes-estree "0.25.1"
hoist-non-react-statics@^3.3.0: hoist-non-react-statics@^3.3.0:
version "3.3.2" version "3.3.2"
resolved "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz" resolved "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz"
@@ -5090,7 +5284,7 @@ mime-db@1.52.0, "mime-db@>= 1.43.0 < 2":
resolved "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz" resolved "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz"
integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==
mime-types@^2.1.27, mime-types@~2.1.34: mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.34:
version "2.1.35" version "2.1.35"
resolved "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz" resolved "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz"
integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==
@@ -5649,7 +5843,7 @@ react-is@^17.0.1:
resolved "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz" resolved "https://registry.npmjs.org/react-is/-/react-is-18.3.1.tgz"
integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg== integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg==
react-native@*, react-native@0.76.1, react-native@>=0.59.0: react-native@*:
version "0.76.1" version "0.76.1"
resolved "https://registry.npmjs.org/react-native/-/react-native-0.76.1.tgz" resolved "https://registry.npmjs.org/react-native/-/react-native-0.76.1.tgz"
integrity sha512-z4KnbrnnAvloRs9NGnah3u6/LK3IbtNMrvByxa3ifigbMlsMY4WPRYV9lvt/hH4Mzt8bfuI+utnOxFyJTTq3lg== integrity sha512-z4KnbrnnAvloRs9NGnah3u6/LK3IbtNMrvByxa3ifigbMlsMY4WPRYV9lvt/hH4Mzt8bfuI+utnOxFyJTTq3lg==
@@ -5693,7 +5887,51 @@ react-native@*, react-native@0.76.1, react-native@>=0.59.0:
babel-plugin-syntax-hermes-parser "^0.23.1" babel-plugin-syntax-hermes-parser "^0.23.1"
"@react-native/community-cli-plugin" "0.76.1" "@react-native/community-cli-plugin" "0.76.1"
"react-native-camera-kit@^14.0.0-beta15": react-native@*, react-native@0.76.3, react-native@>=0.59.0:
version "0.76.3"
resolved "https://registry.npmjs.org/react-native/-/react-native-0.76.3.tgz"
integrity sha512-0TUhgmlouRNf6yuDIIAdbQl0g1VsONgCMsLs7Et64hjj5VLMCA7np+4dMrZvGZ3wRNqzgeyT9oWJsUm49AcwSQ==
dependencies:
ws "^6.2.3"
glob "^7.1.1"
anser "^1.4.9"
chalk "^4.0.0"
yargs "^17.6.2"
mkdirp "^0.5.1"
semver "^7.1.3"
promise "^8.3.0"
base64-js "^1.5.1"
commander "^12.0.0"
invariant "^2.2.4"
scheduler "0.24.0-canary-efb381bbf-20230505"
ansi-regex "^5.0.0"
babel-jest "^29.7.0"
nullthrows "^1.1.1"
jsc-android "^250231.0.0"
memoize-one "^5.0.0"
whatwg-fetch "^3.0.0"
metro-runtime "^0.81.0"
pretty-format "^29.7.0"
react-refresh "^0.14.0"
abort-controller "^3.0.0"
metro-source-map "^0.81.0"
event-target-shim "^5.0.1"
stacktrace-parser "^0.1.10"
flow-enums-runtime "^0.0.6"
react-devtools-core "^5.3.1"
regenerator-runtime "^0.13.2"
"@react-native/codegen" "0.76.3"
jest-environment-node "^29.6.3"
"@react-native/js-polyfills" "0.76.3"
"@react-native/gradle-plugin" "0.76.3"
"@react-native/assets-registry" "0.76.3"
"@react-native/normalize-colors" "0.76.3"
"@jest/create-cache-key-function" "^29.6.3"
"@react-native/virtualized-lists" "0.76.3"
babel-plugin-syntax-hermes-parser "^0.23.1"
"@react-native/community-cli-plugin" "0.76.3"
react-native-camera-kit@^14.1.0:
version "14.1.0" version "14.1.0"
resolved "https://registry.npmjs.org/react-native-camera-kit/-/react-native-camera-kit-14.1.0.tgz" resolved "https://registry.npmjs.org/react-native-camera-kit/-/react-native-camera-kit-14.1.0.tgz"
integrity sha512-idkg+Sa2KbGvF6SUqmuAr2U12qBELdiuUJ6fxgB4whUC2AyYHi5jBxiGv6whY/eTB3is7nW1S+TjyM9pEBzNzw== integrity sha512-idkg+Sa2KbGvF6SUqmuAr2U12qBELdiuUJ6fxgB4whUC2AyYHi5jBxiGv6whY/eTB3is7nW1S+TjyM9pEBzNzw==
@@ -5707,15 +5945,15 @@ react-native-paper@^5.12.5:
color "^3.1.2" color "^3.1.2"
use-latest-callback "^0.1.5" use-latest-callback "^0.1.5"
react-native-safe-area-context@*, react-native-safe-area-context@^4.11.1: react-native-safe-area-context@*, react-native-safe-area-context@^4.14.0:
version "4.14.0" version "4.14.0"
resolved "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.14.0.tgz" resolved "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.14.0.tgz"
integrity sha512-/SyYpCulWQOnnXhRq6wepkhoyQMowHm1ptDyRz20s+YS/R9mbd+mK+jFyFCyXFJn8jp7vFl43VUCgspuOiEbwA== integrity sha512-/SyYpCulWQOnnXhRq6wepkhoyQMowHm1ptDyRz20s+YS/R9mbd+mK+jFyFCyXFJn8jp7vFl43VUCgspuOiEbwA==
react-native-update@^10.15.1: react-native-update@^10.17.1:
version "10.15.3" version "10.17.1"
resolved "https://registry.npmjs.org/react-native-update/-/react-native-update-10.15.3.tgz" resolved "https://registry.npmjs.org/react-native-update/-/react-native-update-10.17.1.tgz"
integrity sha512-PTLZ26Teq0Vc2Ebg1YX9pfmpch4wVgE/tM6dnMlKWpqKP2H2Zqm1U62MHRNsxRkv7sbwC6RANenGYYLFS4P18w== integrity sha512-tc9rP1zuP4TrRe+vEWFC559kbCptBmbvd8ix1mhRprDuOsN7xWYZWrdsAfCGLuPLRSxASGhxObx7lRQP5ECXVA==
dependencies: dependencies:
nanoid "^3.3.3" nanoid "^3.3.3"
react-native-url-polyfill "^2.0.0" react-native-url-polyfill "^2.0.0"
@@ -6535,11 +6773,16 @@ typed-array-length@^1.0.6:
is-typed-array "^1.1.13" is-typed-array "^1.1.13"
possible-typed-array-names "^1.0.0" possible-typed-array-names "^1.0.0"
typescript@5.0.4, "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta", typescript@>=4.2.0: "typescript@>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta", typescript@>=4.2.0:
version "5.0.4" version "5.0.4"
resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.4.tgz" resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.4.tgz"
integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw== integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==
typescript@5.7.2:
version "5.7.2"
resolved "https://registry.npmjs.org/typescript/-/typescript-5.7.2.tgz"
integrity sha512-i5t66RHxDvVN40HfDd1PsEThGNnlMCMT3jMUuoh9/0TaqWevNontacunWyN02LA9/fIbEWlcHZcgTKb9QoaLfg==
unbox-primitive@^1.0.2: unbox-primitive@^1.0.2:
version "1.0.2" version "1.0.2"
resolved "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz" resolved "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz"

View File

@@ -1,7 +1,7 @@
package cn.reactnative.modules.update; package cn.reactnative.modules.update;
import android.app.Activity; import android.app.Activity;
import android.app.Application; import android.content.Context;
import android.util.Log; import android.util.Log;
import com.facebook.react.ReactApplication; import com.facebook.react.ReactApplication;
import com.facebook.react.ReactInstanceManager; import com.facebook.react.ReactInstanceManager;
@@ -117,8 +117,7 @@ public class UpdateModuleImpl {
public void run() { public void run() {
try { try {
updateContext.switchVersion(hash); updateContext.switchVersion(hash);
Activity activity = mContext.getCurrentActivity(); final Context application = mContext.getApplicationContext();
Application application = activity.getApplication();
ReactInstanceManager instanceManager = updateContext.getCustomReactInstanceManager(); ReactInstanceManager instanceManager = updateContext.getCustomReactInstanceManager();
if (instanceManager == null) { if (instanceManager == null) {
@@ -142,7 +141,10 @@ public class UpdateModuleImpl {
promise.resolve(true); promise.resolve(true);
} catch (Throwable err) { } catch (Throwable err) {
promise.reject("pushy:"+err.getMessage()); promise.reject("pushy:"+err.getMessage());
activity.recreate(); final Activity activity = mContext.getCurrentActivity();
if (activity != null) {
activity.recreate();
}
} }
} catch (Throwable err) { } catch (Throwable err) {

View File

@@ -1,7 +1,7 @@
package cn.reactnative.modules.update; package cn.reactnative.modules.update;
import android.app.Activity; import android.app.Activity;
import android.app.Application; import android.content.Context;
import android.content.Intent; import android.content.Intent;
import android.net.Uri; import android.net.Uri;
import android.os.Build; import android.os.Build;
@@ -176,8 +176,7 @@ public class UpdateModule extends ReactContextBaseJavaModule {
public void run() { public void run() {
try { try {
updateContext.switchVersion(hash); updateContext.switchVersion(hash);
Activity activity = getCurrentActivity(); final Context application = getReactApplicationContext().getApplicationContext();
Application application = activity.getApplication();
ReactInstanceManager instanceManager = updateContext.getCustomReactInstanceManager(); ReactInstanceManager instanceManager = updateContext.getCustomReactInstanceManager();
if (instanceManager == null) { if (instanceManager == null) {
@@ -200,7 +199,10 @@ public class UpdateModule extends ReactContextBaseJavaModule {
instanceManager.recreateReactContextInBackground(); instanceManager.recreateReactContextInBackground();
promise.resolve(null); promise.resolve(null);
} catch (Throwable err) { } catch (Throwable err) {
activity.recreate(); final Activity activity = getCurrentActivity();
if (activity != null) {
activity.recreate();
}
promise.reject(err); promise.reject(err);
} }

View File

@@ -1,6 +1,10 @@
#import "RCTPushy.h" #import "RCTPushy.h"
#import "RCTPushyDownloader.h" #import "RCTPushyDownloader.h"
#import "RCTPushyManager.h" #import "RCTPushyManager.h"
#if __has_include("RCTReloadCommand.h")
#import "RCTReloadCommand.h"
#endif
// Thanks to this guard, we won't import this header when we build for the old architecture. // Thanks to this guard, we won't import this header when we build for the old architecture.
#ifdef RCT_NEW_ARCH_ENABLED #ifdef RCT_NEW_ARCH_ENABLED
#import "RCTPushySpec.h" #import "RCTPushySpec.h"
@@ -311,14 +315,17 @@ RCT_EXPORT_METHOD(reloadUpdate:(NSDictionary *)options
if (hash.length) { if (hash.length) {
[self setNeedUpdate:options resolver:resolve rejecter:reject]; [self setNeedUpdate:options resolver:resolve rejecter:reject];
// reload 0.62+ #if __has_include("RCTReloadCommand.h")
// RCTReloadCommandSetBundleURL([[self class] bundleURL]); // reload 0.62+
// RCTTriggerReloadCommandListeners(@"pushy reload"); RCTReloadCommandSetBundleURL([[self class] bundleURL]);
RCTTriggerReloadCommandListeners(@"pushy reload");
dispatch_async(dispatch_get_main_queue(), ^{ #else
[self.bridge setValue:[[self class] bundleURL] forKey:@"bundleURL"]; // reload in earlier version
[self.bridge reload]; dispatch_async(dispatch_get_main_queue(), ^{
}); [self.bridge setValue:[[self class] bundleURL] forKey:@"bundleURL"];
[self.bridge reload];
});
#endif
resolve(@true); resolve(@true);
}else{ }else{
reject(@"执行报错", nil, nil); reject(@"执行报错", nil, nil);

View File

@@ -1,6 +1,6 @@
{ {
"name": "react-native-update", "name": "react-native-update",
"version": "10.17.0", "version": "10.19.1",
"description": "react-native hot update", "description": "react-native hot update",
"main": "src/index", "main": "src/index",
"scripts": { "scripts": {

View File

@@ -41,12 +41,12 @@ const ping =
Promise.race([ Promise.race([
fetch(url, { fetch(url, {
method: 'HEAD', method: 'HEAD',
}).then(({ status }) => (status === 200 ? url : null)), })
.then(({ status }) => (status === 200 ? url : null))
.catch(() => null),
new Promise(r => setTimeout(() => r(null), 2000)), new Promise(r => setTimeout(() => r(null), 2000)),
]); ]);
const canUseGoogle = ping('https://www.google.com');
export function joinUrls(paths: string[], fileName?: string) { export function joinUrls(paths: string[], fileName?: string) {
if (fileName) { if (fileName) {
return paths.map(path => 'https://' + path + '/' + fileName); return paths.map(path => 'https://' + path + '/' + fileName);
@@ -57,8 +57,5 @@ export const testUrls = async (urls?: string[]) => {
if (!urls?.length) { if (!urls?.length) {
return null; return null;
} }
if (await canUseGoogle) {
return urls[0];
}
return promiseAny(urls.map(ping)).catch(() => null); return promiseAny(urls.map(ping)).catch(() => null);
}; };