From 9c4e1907acd83f87500ced48524b516b8d98b658 Mon Sep 17 00:00:00 2001 From: FreakyCoder Date: Mon, 27 Feb 2023 14:26:46 +0300 Subject: [PATCH] chore: android and ios are tested with the newest dependencies --- android/app/build.gradle | 13 +- .../rntypescriptboilerplate/MainActivity.java | 10 + .../MainApplication.java | 5 - .../ReactNativeFlipper.java | 18 - ios/Podfile | 39 +- ios/Podfile.lock | 610 ++++++++++-------- .../project.pbxproj | 6 +- ios/RNTypescriptBoilerplate/AppDelegate.h | 7 +- ios/RNTypescriptBoilerplate/AppDelegate.mm | 121 +--- ios/RNTypescriptBoilerplate/Info.plist | 4 +- package-lock.json | 136 +--- package.json | 7 +- src/navigation/index.tsx | 13 +- src/screens/home/HomeScreen.tsx | 11 +- tsconfig.json | 1 + 15 files changed, 450 insertions(+), 551 deletions(-) delete mode 100644 android/app/src/main/java/com/rntypescriptboilerplate/ReactNativeFlipper.java diff --git a/android/app/build.gradle b/android/app/build.gradle index 0a89e06..e193105 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -56,7 +56,7 @@ react { def enableSeparateBuildPerCPUArchitecture = false def enableProguardInReleaseBuilds = false def jscFlavor = 'org.webkit:android-jsc:+' -def enableHermes = project.ext.react.get("enableHermes", false); +//def enableHermes = project.ext.react.get("enableHermes", false); def reactNativeArchitectures() { def value = project.getProperties().get("reactNativeArchitectures") @@ -127,22 +127,13 @@ android { } } - - packagingOptions { - pickFirst '**/armeabi-v7a/libc++_shared.so' - pickFirst '**/x86/libc++_shared.so' - pickFirst '**/arm64-v8a/libc++_shared.so' - pickFirst '**/x86_64/libc++_shared.so' - pickFirst '**/x86/libjsc.so' - pickFirst '**/armeabi-v7a/libjsc.so' - } } dependencies { // The version of react-native is set by the React Native Gradle Plugin implementation("com.facebook.react:react-android") - implementation "androidx.swiperefreshlayout:swiperefreshlayout:1.0.0" + implementation("androidx.swiperefreshlayout:swiperefreshlayout:1.0.0") debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") { diff --git a/android/app/src/main/java/com/rntypescriptboilerplate/MainActivity.java b/android/app/src/main/java/com/rntypescriptboilerplate/MainActivity.java index 90e1d26..d77796c 100644 --- a/android/app/src/main/java/com/rntypescriptboilerplate/MainActivity.java +++ b/android/app/src/main/java/com/rntypescriptboilerplate/MainActivity.java @@ -5,8 +5,18 @@ import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint; import com.facebook.react.defaults.DefaultReactActivityDelegate; +// SplashScreen Imports +import android.os.Bundle; +import org.devio.rn.splashscreen.SplashScreen; + public class MainActivity extends ReactActivity { + + @Override + protected void onCreate(Bundle savedInstanceState) { + SplashScreen.show(this); + super.onCreate(savedInstanceState); + } /** * Returns the name of the main component registered from JavaScript. This is used to schedule * rendering of the component. diff --git a/android/app/src/main/java/com/rntypescriptboilerplate/MainApplication.java b/android/app/src/main/java/com/rntypescriptboilerplate/MainApplication.java index d50f590..9fa8fb1 100644 --- a/android/app/src/main/java/com/rntypescriptboilerplate/MainApplication.java +++ b/android/app/src/main/java/com/rntypescriptboilerplate/MainApplication.java @@ -10,7 +10,6 @@ import com.facebook.react.defaults.DefaultReactNativeHost; import com.facebook.soloader.SoLoader; import java.util.List; -import com.swmansion.reanimated.ReanimatedJSIModulePackage; public class MainApplication extends Application implements ReactApplication { @@ -45,10 +44,6 @@ protected Boolean isHermesEnabled() { return BuildConfig.IS_HERMES_ENABLED; } - @Override - protected JSIModulePackage getJSIModulePackage() { - return new ReanimatedJSIModulePackage(); - } }; @Override diff --git a/android/app/src/main/java/com/rntypescriptboilerplate/ReactNativeFlipper.java b/android/app/src/main/java/com/rntypescriptboilerplate/ReactNativeFlipper.java deleted file mode 100644 index f42dc0d..0000000 --- a/android/app/src/main/java/com/rntypescriptboilerplate/ReactNativeFlipper.java +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - *

This source code is licensed under the MIT license found in the LICENSE file in the root - * directory of this source tree. - */ -package com.rndiffapp; -import android.content.Context; -import com.facebook.react.ReactInstanceManager; -/** - * Class responsible of loading Flipper inside your React Native application. This is the release - * flavor of it so it's empty as we don't want to load Flipper. - */ -public class ReactNativeFlipper { - public static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) { - // Do nothing as we don't want to initialize Flipper on Release. - } -} diff --git a/ios/Podfile b/ios/Podfile index c3fa624..f154093 100644 --- a/ios/Podfile +++ b/ios/Podfile @@ -1,10 +1,25 @@ require_relative '../node_modules/react-native/scripts/react_native_pods' require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules' -platform :ios, '12.4' -install! 'cocoapods', :deterministic_uuids => false +platform :ios, min_ios_version_supported +prepare_react_native_project! -production = ENV["PRODUCTION"] == "1" +# 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 = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled + +linkage = ENV['USE_FRAMEWORKS'] +if linkage != nil + Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green + use_frameworks! :linkage => linkage.to_sym +end target 'RNTypescriptBoilerplate' do config = use_native_modules! @@ -13,12 +28,17 @@ target 'RNTypescriptBoilerplate' do flags = get_default_flags() use_react_native!( - :production => production, :path => config[:reactNativePath], - # to enable hermes on iOS, change `false` to `true` and then install pods + # Hermes is now enabled by default. Disable by setting this flag to false. + # Upcoming versions of React Native may rely on get_default_flags(), but + # we make it explicit here to aid in the React Native upgrade process. :hermes_enabled => flags[:hermes_enabled], :fabric_enabled => flags[:fabric_enabled], - :flipper_configuration => FlipperConfiguration.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. :app_path => "#{Pod::Config.instance.installation_root}/.." ) @@ -29,7 +49,12 @@ target 'RNTypescriptBoilerplate' do end post_install do |installer| - react_native_post_install(installer) + react_native_post_install( + installer, + # Set `mac_catalyst_enabled` to `true` in order to apply patches + # necessary for Mac Catalyst builds + :mac_catalyst_enabled => false + ) __apply_Xcode_12_5_M1_post_install_workaround(installer) end end diff --git a/ios/Podfile.lock b/ios/Podfile.lock index 3b9c472..a524bd5 100644 --- a/ios/Podfile.lock +++ b/ios/Podfile.lock @@ -2,14 +2,14 @@ PODS: - boost (1.76.0) - CocoaAsyncSocket (7.6.5) - DoubleConversion (1.1.6) - - FBLazyVector (0.69.4) - - FBReactNativeSpec (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTRequired (= 0.69.4) - - RCTTypeSafety (= 0.69.4) - - React-Core (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) + - FBLazyVector (0.71.3) + - FBReactNativeSpec (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTRequired (= 0.71.3) + - RCTTypeSafety (= 0.71.3) + - React-Core (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) - Flipper (0.125.0): - Flipper-Folly (~> 2.6) - Flipper-RSocket (~> 1.4) @@ -73,300 +73,361 @@ PODS: - FlipperKit/FlipperKitNetworkPlugin - fmt (6.2.1) - glog (0.3.5) + - hermes-engine (0.71.3): + - hermes-engine/Pre-built (= 0.71.3) + - hermes-engine/Pre-built (0.71.3) - libevent (2.1.12) - OpenSSL-Universal (1.1.1100) - - RCT-Folly (2021.06.28.00-v2): + - RCT-Folly (2021.07.22.00): - boost - DoubleConversion - fmt (~> 6.2.1) - glog - - RCT-Folly/Default (= 2021.06.28.00-v2) - - RCT-Folly/Default (2021.06.28.00-v2): + - RCT-Folly/Default (= 2021.07.22.00) + - RCT-Folly/Default (2021.07.22.00): - boost - DoubleConversion - fmt (~> 6.2.1) - glog - - RCTRequired (0.69.4) - - RCTTypeSafety (0.69.4): - - FBLazyVector (= 0.69.4) - - RCTRequired (= 0.69.4) - - React-Core (= 0.69.4) - - React (0.69.4): - - React-Core (= 0.69.4) - - React-Core/DevSupport (= 0.69.4) - - React-Core/RCTWebSocket (= 0.69.4) - - React-RCTActionSheet (= 0.69.4) - - React-RCTAnimation (= 0.69.4) - - React-RCTBlob (= 0.69.4) - - React-RCTImage (= 0.69.4) - - React-RCTLinking (= 0.69.4) - - React-RCTNetwork (= 0.69.4) - - React-RCTSettings (= 0.69.4) - - React-RCTText (= 0.69.4) - - React-RCTVibration (= 0.69.4) - - React-bridging (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - React-jsi (= 0.69.4) - - React-callinvoker (0.69.4) - - React-Codegen (0.69.4): - - FBReactNativeSpec (= 0.69.4) - - RCT-Folly (= 2021.06.28.00-v2) - - RCTRequired (= 0.69.4) - - RCTTypeSafety (= 0.69.4) - - React-Core (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-Core (0.69.4): + - RCT-Folly/Futures (2021.07.22.00): + - boost + - DoubleConversion + - fmt (~> 6.2.1) + - glog + - libevent + - RCTRequired (0.71.3) + - RCTTypeSafety (0.71.3): + - FBLazyVector (= 0.71.3) + - RCTRequired (= 0.71.3) + - React-Core (= 0.71.3) + - React (0.71.3): + - React-Core (= 0.71.3) + - React-Core/DevSupport (= 0.71.3) + - React-Core/RCTWebSocket (= 0.71.3) + - React-RCTActionSheet (= 0.71.3) + - React-RCTAnimation (= 0.71.3) + - React-RCTBlob (= 0.71.3) + - React-RCTImage (= 0.71.3) + - React-RCTLinking (= 0.71.3) + - React-RCTNetwork (= 0.71.3) + - React-RCTSettings (= 0.71.3) + - React-RCTText (= 0.71.3) + - React-RCTVibration (= 0.71.3) + - React-callinvoker (0.71.3) + - React-Codegen (0.71.3): + - FBReactNativeSpec + - hermes-engine + - RCT-Folly + - RCTRequired + - RCTTypeSafety + - React-Core + - React-jsi + - React-jsiexecutor + - ReactCommon/turbomodule/bridging + - ReactCommon/turbomodule/core + - React-Core (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.4) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-Core/Default (= 0.71.3) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/CoreModulesHeaders (0.69.4): + - React-Core/CoreModulesHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/Default (0.69.4): + - React-Core/Default (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/DevSupport (0.69.4): + - React-Core/DevSupport (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.4) - - React-Core/RCTWebSocket (= 0.69.4) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-jsinspector (= 0.69.4) - - React-perflogger (= 0.69.4) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-Core/Default (= 0.71.3) + - React-Core/RCTWebSocket (= 0.71.3) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-jsinspector (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTActionSheetHeaders (0.69.4): + - React-Core/RCTActionSheetHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTAnimationHeaders (0.69.4): + - React-Core/RCTAnimationHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTBlobHeaders (0.69.4): + - React-Core/RCTBlobHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTImageHeaders (0.69.4): + - React-Core/RCTImageHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTLinkingHeaders (0.69.4): + - React-Core/RCTLinkingHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTNetworkHeaders (0.69.4): + - React-Core/RCTNetworkHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTSettingsHeaders (0.69.4): + - React-Core/RCTSettingsHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTTextHeaders (0.69.4): + - React-Core/RCTTextHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTVibrationHeaders (0.69.4): + - React-Core/RCTVibrationHeaders (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) - React-Core/Default - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-Core/RCTWebSocket (0.69.4): + - React-Core/RCTWebSocket (0.71.3): - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-Core/Default (= 0.69.4) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsiexecutor (= 0.69.4) - - React-perflogger (= 0.69.4) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-Core/Default (= 0.71.3) + - React-cxxreact (= 0.71.3) + - React-hermes + - React-jsi (= 0.71.3) + - React-jsiexecutor (= 0.71.3) + - React-perflogger (= 0.71.3) - Yoga - - React-CoreModules (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.4) - - React-Codegen (= 0.69.4) - - React-Core/CoreModulesHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - React-RCTImage (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-cxxreact (0.69.4): + - React-CoreModules (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTTypeSafety (= 0.71.3) + - React-Codegen (= 0.71.3) + - React-Core/CoreModulesHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - React-RCTBlob + - React-RCTImage (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-cxxreact (0.71.3): - boost (= 1.76.0) - DoubleConversion - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-callinvoker (= 0.69.4) - - React-jsi (= 0.69.4) - - React-jsinspector (= 0.69.4) - - React-logger (= 0.69.4) - - React-perflogger (= 0.69.4) - - React-runtimeexecutor (= 0.69.4) - - React-jsi (0.69.4): - - boost (= 1.76.0) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-callinvoker (= 0.71.3) + - React-jsi (= 0.71.3) + - React-jsinspector (= 0.71.3) + - React-logger (= 0.71.3) + - React-perflogger (= 0.71.3) + - React-runtimeexecutor (= 0.71.3) + - React-hermes (0.71.3): - DoubleConversion - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-jsi/Default (= 0.69.4) - - React-jsi/Default (0.69.4): + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - RCT-Folly/Futures (= 2021.07.22.00) + - React-cxxreact (= 0.71.3) + - React-jsi + - React-jsiexecutor (= 0.71.3) + - React-jsinspector (= 0.71.3) + - React-perflogger (= 0.71.3) + - React-jsi (0.71.3): - boost (= 1.76.0) - DoubleConversion - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-jsiexecutor (0.69.4): + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-jsiexecutor (0.71.3): - DoubleConversion - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-perflogger (= 0.69.4) - - React-jsinspector (0.69.4) - - React-logger (0.69.4): + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-cxxreact (= 0.71.3) + - React-jsi (= 0.71.3) + - React-perflogger (= 0.71.3) + - React-jsinspector (0.71.3) + - React-logger (0.71.3): - glog - - react-native-safe-area-context (4.3.1): + - react-native-safe-area-context (4.5.0): - RCT-Folly - RCTRequired - RCTTypeSafety - - React + - React-Core - ReactCommon/turbomodule/core - react-native-splash-screen (3.3.0): - React-Core - - React-perflogger (0.69.4) - - React-RCTActionSheet (0.69.4): - - React-Core/RCTActionSheetHeaders (= 0.69.4) - - React-RCTAnimation (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.4) - - React-Codegen (= 0.69.4) - - React-Core/RCTAnimationHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTBlob (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - React-Codegen (= 0.69.4) - - React-Core/RCTBlobHeaders (= 0.69.4) - - React-Core/RCTWebSocket (= 0.69.4) - - React-jsi (= 0.69.4) - - React-RCTNetwork (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTImage (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.4) - - React-Codegen (= 0.69.4) - - React-Core/RCTImageHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - React-RCTNetwork (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTLinking (0.69.4): - - React-Codegen (= 0.69.4) - - React-Core/RCTLinkingHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTNetwork (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.4) - - React-Codegen (= 0.69.4) - - React-Core/RCTNetworkHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTSettings (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - RCTTypeSafety (= 0.69.4) - - React-Codegen (= 0.69.4) - - React-Core/RCTSettingsHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-RCTText (0.69.4): - - React-Core/RCTTextHeaders (= 0.69.4) - - React-RCTVibration (0.69.4): - - RCT-Folly (= 2021.06.28.00-v2) - - React-Codegen (= 0.69.4) - - React-Core/RCTVibrationHeaders (= 0.69.4) - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (= 0.69.4) - - React-runtimeexecutor (0.69.4): - - React-jsi (= 0.69.4) - - ReactCommon/turbomodule/core (0.69.4): + - React-perflogger (0.71.3) + - React-RCTActionSheet (0.71.3): + - React-Core/RCTActionSheetHeaders (= 0.71.3) + - React-RCTAnimation (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTTypeSafety (= 0.71.3) + - React-Codegen (= 0.71.3) + - React-Core/RCTAnimationHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTAppDelegate (0.71.3): + - RCT-Folly + - RCTRequired + - RCTTypeSafety + - React-Core + - ReactCommon/turbomodule/core + - React-RCTBlob (0.71.3): + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-Codegen (= 0.71.3) + - React-Core/RCTBlobHeaders (= 0.71.3) + - React-Core/RCTWebSocket (= 0.71.3) + - React-jsi (= 0.71.3) + - React-RCTNetwork (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTImage (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTTypeSafety (= 0.71.3) + - React-Codegen (= 0.71.3) + - React-Core/RCTImageHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - React-RCTNetwork (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTLinking (0.71.3): + - React-Codegen (= 0.71.3) + - React-Core/RCTLinkingHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTNetwork (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTTypeSafety (= 0.71.3) + - React-Codegen (= 0.71.3) + - React-Core/RCTNetworkHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTSettings (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - RCTTypeSafety (= 0.71.3) + - React-Codegen (= 0.71.3) + - React-Core/RCTSettingsHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-RCTText (0.71.3): + - React-Core/RCTTextHeaders (= 0.71.3) + - React-RCTVibration (0.71.3): + - RCT-Folly (= 2021.07.22.00) + - React-Codegen (= 0.71.3) + - React-Core/RCTVibrationHeaders (= 0.71.3) + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/core (= 0.71.3) + - React-runtimeexecutor (0.71.3): + - React-jsi (= 0.71.3) + - ReactCommon/turbomodule/bridging (0.71.3): + - DoubleConversion + - glog + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-callinvoker (= 0.71.3) + - React-Core (= 0.71.3) + - React-cxxreact (= 0.71.3) + - React-jsi (= 0.71.3) + - React-logger (= 0.71.3) + - React-perflogger (= 0.71.3) + - ReactCommon/turbomodule/core (0.71.3): - DoubleConversion - glog - - RCT-Folly (= 2021.06.28.00-v2) - - React-bridging (= 0.69.4) - - React-callinvoker (= 0.69.4) - - React-Core (= 0.69.4) - - React-cxxreact (= 0.69.4) - - React-jsi (= 0.69.4) - - React-logger (= 0.69.4) - - React-perflogger (= 0.69.4) + - hermes-engine + - RCT-Folly (= 2021.07.22.00) + - React-callinvoker (= 0.71.3) + - React-Core (= 0.71.3) + - React-cxxreact (= 0.71.3) + - React-jsi (= 0.71.3) + - React-logger (= 0.71.3) + - React-perflogger (= 0.71.3) - ReactNativeLocalization (2.3.1): - React-Core - - RNCAsyncStorage (1.17.9): - - React-Core - RNCMaskedView (0.2.7): - React-Core - - RNGestureHandler (2.5.0): + - RNGestureHandler (2.9.0): - React-Core - - RNReanimated (2.9.1): + - RNReanimated (2.14.4): - DoubleConversion - FBLazyVector - FBReactNativeSpec @@ -430,12 +491,13 @@ DEPENDENCIES: - FlipperKit/FlipperKitUserDefaultsPlugin (= 0.125.0) - FlipperKit/SKIOSNetworkPlugin (= 0.125.0) - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) + - hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`) + - libevent (~> 2.1.12) - OpenSSL-Universal (= 1.1.1100) - RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`) - RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`) - RCTTypeSafety (from `../node_modules/react-native/Libraries/TypeSafety`) - React (from `../node_modules/react-native/`) - - React-bridging (from `../node_modules/react-native/ReactCommon`) - React-callinvoker (from `../node_modules/react-native/ReactCommon/callinvoker`) - React-Codegen (from `build/generated/ios`) - React-Core (from `../node_modules/react-native/`) @@ -443,6 +505,7 @@ DEPENDENCIES: - React-Core/RCTWebSocket (from `../node_modules/react-native/`) - React-CoreModules (from `../node_modules/react-native/React/CoreModules`) - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`) + - React-hermes (from `../node_modules/react-native/ReactCommon/hermes`) - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`) - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`) - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector`) @@ -452,6 +515,7 @@ DEPENDENCIES: - React-perflogger (from `../node_modules/react-native/ReactCommon/reactperflogger`) - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`) - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`) + - React-RCTAppDelegate (from `../node_modules/react-native/Libraries/AppDelegate`) - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`) - React-RCTImage (from `../node_modules/react-native/Libraries/Image`) - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`) @@ -462,7 +526,6 @@ DEPENDENCIES: - React-runtimeexecutor (from `../node_modules/react-native/ReactCommon/runtimeexecutor`) - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`) - ReactNativeLocalization (from `../node_modules/react-native-localization`) - - "RNCAsyncStorage (from `../node_modules/@react-native-async-storage/async-storage`)" - "RNCMaskedView (from `../node_modules/@react-native-masked-view/masked-view`)" - RNGestureHandler (from `../node_modules/react-native-gesture-handler`) - RNReanimated (from `../node_modules/react-native-reanimated`) @@ -499,6 +562,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/React/FBReactNativeSpec" glog: :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec" + hermes-engine: + :podspec: "../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec" RCT-Folly: :podspec: "../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec" RCTRequired: @@ -507,8 +572,6 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/Libraries/TypeSafety" React: :path: "../node_modules/react-native/" - React-bridging: - :path: "../node_modules/react-native/ReactCommon" React-callinvoker: :path: "../node_modules/react-native/ReactCommon/callinvoker" React-Codegen: @@ -519,6 +582,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/React/CoreModules" React-cxxreact: :path: "../node_modules/react-native/ReactCommon/cxxreact" + React-hermes: + :path: "../node_modules/react-native/ReactCommon/hermes" React-jsi: :path: "../node_modules/react-native/ReactCommon/jsi" React-jsiexecutor: @@ -537,6 +602,8 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/Libraries/ActionSheetIOS" React-RCTAnimation: :path: "../node_modules/react-native/Libraries/NativeAnimation" + React-RCTAppDelegate: + :path: "../node_modules/react-native/Libraries/AppDelegate" React-RCTBlob: :path: "../node_modules/react-native/Libraries/Blob" React-RCTImage: @@ -557,8 +624,6 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/ReactCommon" ReactNativeLocalization: :path: "../node_modules/react-native-localization" - RNCAsyncStorage: - :path: "../node_modules/@react-native-async-storage/async-storage" RNCMaskedView: :path: "../node_modules/@react-native-masked-view/masked-view" RNGestureHandler: @@ -573,11 +638,11 @@ EXTERNAL SOURCES: :path: "../node_modules/react-native/ReactCommon/yoga" SPEC CHECKSUMS: - boost: a7c83b31436843459a1961bfd74b96033dc77234 + boost: 57d2868c099736d80fcd648bf211b4431e51a558 CocoaAsyncSocket: 065fd1e645c7abab64f7a6a2007a48038fdc6a99 DoubleConversion: 5189b271737e1565bdce30deb4a08d647e3f5f54 - FBLazyVector: c71b8c429a8af2aff1013934a7152e9d9d0c937d - FBReactNativeSpec: cb0df4f0084281b394f76bb9b4d1d9540f35963f + FBLazyVector: 60195509584153283780abdac5569feffb8f08cc + FBReactNativeSpec: 9c191fb58d06dc05ab5559a5505fc32139e9e4a2 Flipper: 26fc4b7382499f1281eb8cb921e5c3ad6de91fe0 Flipper-Boost-iOSX: fd1e2b8cbef7e662a122412d7ac5f5bea715403c Flipper-DoubleConversion: 2dc99b02f658daf147069aad9dbd29d8feb06d30 @@ -588,48 +653,49 @@ SPEC CHECKSUMS: Flipper-RSocket: d9d9ade67cbecf6ac10730304bf5607266dd2541 FlipperKit: cbdee19bdd4e7f05472a66ce290f1b729ba3cb86 fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9 - glog: 3d02b25ca00c2d456734d0bcff864cbc62f6ae1a + glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b + hermes-engine: 38bfe887e456b33b697187570a08de33969f5db7 libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913 OpenSSL-Universal: ebc357f1e6bc71fa463ccb2fe676756aff50e88c - RCT-Folly: b9d9fe1fc70114b751c076104e52f3b1b5e5a95a - RCTRequired: bd9d2ab0fda10171fcbcf9ba61a7df4dc15a28f4 - RCTTypeSafety: e44e139bf6ec8042db396201834fc2372f6a21cd - React: 482cd1ba23c471be1aed3800180be2427418d7be - React-bridging: c2ea4fed6fe4ed27c12fd71e88b5d5d3da107fde - React-callinvoker: d4d1f98163fb5e35545e910415ef6c04796bb188 - React-Codegen: ff35fb9c7f6ec2ed34fb6de2e1099d88dfb25f2f - React-Core: 4d3443a45b67c71d74d7243ddde9569d1e4f4fad - React-CoreModules: 70be25399366b5632ab18ecf6fe444a8165a7bea - React-cxxreact: 822d3794fc0bf206f4691592f90e086dd4f92228 - React-jsi: ffa51cbc9a78cc156cf61f79ed52ecb76dc6013b - React-jsiexecutor: a27badbbdbc0ff781813370736a2d1c7261181d4 - React-jsinspector: 8a3d3f5dcd23a91e8c80b1bf0e96902cd1dca999 - React-logger: 1088859f145b8f6dd0d3ed051a647ef0e3e80fad - react-native-safe-area-context: 6c12e3859b6f27b25de4fee8201cfb858432d8de + RCT-Folly: 424b8c9a7a0b9ab2886ffe9c3b041ef628fd4fb1 + RCTRequired: bec48f07daf7bcdc2655a0cde84e07d24d2a9e2a + RCTTypeSafety: 171394eebacf71e1cfad79dbfae7ee8fc16ca80a + React: d7433ccb6a8c36e4cbed59a73c0700fc83c3e98a + React-callinvoker: 15f165009bd22ae829b2b600e50bcc98076ce4b8 + React-Codegen: b5910000eaf1e0c2f47d29be6f82f5f1264420d7 + React-Core: b6f2f78d580a90b83fd7b0d1c6911c799f6eac82 + React-CoreModules: e0cbc1a4f4f3f60e23c476fef7ab37be363ea8c1 + React-cxxreact: c87f3f124b2117d00d410b35f16c2257e25e50fa + React-hermes: c64ca6bdf16a7069773103c9bedaf30ec90ab38f + React-jsi: 39729361645568e238081b3b3180fbad803f25a4 + React-jsiexecutor: 515b703d23ffadeac7687bc2d12fb08b90f0aaa1 + React-jsinspector: 9f7c9137605e72ca0343db4cea88006cb94856dd + React-logger: 957e5dc96d9dbffc6e0f15e0ee4d2b42829ff207 + react-native-safe-area-context: 39c2d8be3328df5d437ac1700f4f3a4f75716acc react-native-splash-screen: 4312f786b13a81b5169ef346d76d33bc0c6dc457 - React-perflogger: cb386fd44c97ec7f8199c04c12b22066b0f2e1e0 - React-RCTActionSheet: f803a85e46cf5b4066c2ac5e122447f918e9c6e5 - React-RCTAnimation: 19c80fa950ccce7f4db76a2a7f2cf79baae07fc7 - React-RCTBlob: f36ab97e2d515c36df14a1571e50056be80413d5 - React-RCTImage: 2c8f0a329a116248e82f8972ffe806e47c6d1cfa - React-RCTLinking: 670f0223075aff33be3b89714f1da4f5343fc4af - React-RCTNetwork: 09385b73f4ff1f46bd5d749540fb33f69a7e5908 - React-RCTSettings: 33b12d3ac7a1f2eba069ec7bd1b84345263b3bbe - React-RCTText: a1a3ea902403bd9ae4cf6f7960551dc1d25711b5 - React-RCTVibration: 9adb4a3cbb598d1bbd46a05256f445e4b8c70603 - React-runtimeexecutor: 61ee22a8cdf8b6bb2a7fb7b4ba2cc763e5285196 - ReactCommon: 8f67bd7e0a6afade0f20718f859dc8c2275f2e83 + React-perflogger: af8a3d31546077f42d729b949925cc4549f14def + React-RCTActionSheet: 57cc5adfefbaaf0aae2cf7e10bccd746f2903673 + React-RCTAnimation: 11c61e94da700c4dc915cf134513764d87fc5e2b + React-RCTAppDelegate: c3980adeaadcfd6cb495532e928b36ac6db3c14a + React-RCTBlob: ccc5049d742b41971141415ca86b83b201495695 + React-RCTImage: 7a9226b0944f1e76e8e01e35a9245c2477cdbabb + React-RCTLinking: bbe8cc582046a9c04f79c235b73c93700263e8b4 + React-RCTNetwork: fc2ca322159dc54e06508d4f5c3e934da63dc013 + React-RCTSettings: f1e9db2cdf946426d3f2b210e4ff4ce0f0d842ef + React-RCTText: 1c41dd57e5d742b1396b4eeb251851ce7ff0fca1 + React-RCTVibration: 5199a180d04873366a83855de55ac33ce60fe4d5 + React-runtimeexecutor: 7bf0dafc7b727d93c8cb94eb00a9d3753c446c3e + ReactCommon: 6f65ea5b7d84deb9e386f670dd11ce499ded7b40 ReactNativeLocalization: 076497d7ca70341c751cd3b3e7c86187332a182d - RNCAsyncStorage: b2489b49e38c85e10ed45a888d13a2a4c7b32ea1 RNCMaskedView: cb9670ea9239998340eaab21df13fa12a1f9de15 - RNGestureHandler: bad495418bcbd3ab47017a38d93d290ebd406f50 - RNReanimated: 2cf7451318bb9cc430abeec8d67693f9cf4e039c + RNGestureHandler: 071d7a9ad81e8b83fe7663b303d132406a7d8f39 + RNReanimated: cc5e3aa479cb9170bcccf8204291a6950a3be128 RNScreens: 4a1af06327774490d97342c00aee0c2bafb497b7 RNVectorIcons: fcc2f6cb32f5735b586e66d14103a74ce6ad61f8 SocketRocket: fccef3f9c5cedea1353a9ef6ada904fde10d6608 - Yoga: ff994563b2fd98c982ca58e8cd9db2cdaf4dda74 + Yoga: 5ed1699acbba8863755998a4245daa200ff3817b YogaKit: f782866e155069a2cca2517aafea43200b01fd5a -PODFILE CHECKSUM: 196a4151ccaa0ea380d92f5ec538e20bc539f9fe +PODFILE CHECKSUM: 3881aa53486085a47d7330679841a11f41ded866 COCOAPODS: 1.11.3 diff --git a/ios/RNTypescriptBoilerplate.xcodeproj/project.pbxproj b/ios/RNTypescriptBoilerplate.xcodeproj/project.pbxproj index 4380bf0..189d387 100644 --- a/ios/RNTypescriptBoilerplate.xcodeproj/project.pbxproj +++ b/ios/RNTypescriptBoilerplate.xcodeproj/project.pbxproj @@ -573,6 +573,7 @@ "$(inherited)", "@executable_path/Frameworks", ); + MARKETING_VERSION = 1.0; OTHER_LDFLAGS = ( "$(inherited)", "-ObjC", @@ -598,6 +599,7 @@ "$(inherited)", "@executable_path/Frameworks", ); + MARKETING_VERSION = 1.0; OTHER_LDFLAGS = ( "$(inherited)", "-ObjC", @@ -643,7 +645,7 @@ COPY_PHASE_STRIP = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; - "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = ""; + "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_DYNAMIC_NO_PIC = NO; GCC_NO_COMMON_BLOCKS = YES; @@ -715,7 +717,7 @@ COPY_PHASE_STRIP = YES; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; - "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = ""; + "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386; GCC_C_LANGUAGE_STANDARD = gnu99; GCC_NO_COMMON_BLOCKS = YES; GCC_WARN_64_TO_32_BIT_CONVERSION = YES; diff --git a/ios/RNTypescriptBoilerplate/AppDelegate.h b/ios/RNTypescriptBoilerplate/AppDelegate.h index ef1de86..c59b2ef 100644 --- a/ios/RNTypescriptBoilerplate/AppDelegate.h +++ b/ios/RNTypescriptBoilerplate/AppDelegate.h @@ -1,8 +1,5 @@ -#import +#import #import -@interface AppDelegate : UIResponder - -@property (nonatomic, strong) UIWindow *window; - +@interface AppDelegate : RCTAppDelegate @end diff --git a/ios/RNTypescriptBoilerplate/AppDelegate.mm b/ios/RNTypescriptBoilerplate/AppDelegate.mm index 1a9e41b..de0c257 100644 --- a/ios/RNTypescriptBoilerplate/AppDelegate.mm +++ b/ios/RNTypescriptBoilerplate/AppDelegate.mm @@ -1,84 +1,22 @@ #import "AppDelegate.h" -#import #import -#import -#import #import "RNSplashScreen.h" -#if RCT_NEW_ARCH_ENABLED -#import -#import -#import -#import -#import -#import -#import - -static NSString *const kRNConcurrentRoot = @"concurrentRoot"; - -@interface AppDelegate () { - RCTTurboModuleManager *_turboModuleManager; - RCTSurfacePresenterBridgeAdapter *_bridgeAdapter; - std::shared_ptr _reactNativeConfig; - facebook::react::ContextContainer::Shared _contextContainer; -} -@end -#endif - @implementation AppDelegate + - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { - RCTAppSetupPrepareApp(application); - - RCTBridge *bridge = [[RCTBridge alloc] initWithDelegate:self launchOptions:launchOptions]; - -#if RCT_NEW_ARCH_ENABLED - _contextContainer = std::make_shared(); - _reactNativeConfig = std::make_shared(); - _contextContainer->insert("ReactNativeConfig", _reactNativeConfig); - _bridgeAdapter = [[RCTSurfacePresenterBridgeAdapter alloc] initWithBridge:bridge contextContainer:_contextContainer]; - bridge.surfacePresenter = _bridgeAdapter.surfacePresenter; -#endif - - NSDictionary *initProps = [self prepareInitialProps]; - UIView *rootView = RCTAppSetupDefaultRootView(bridge, @"RNTypescriptBoilerplate", initProps); - - if (@available(iOS 13.0, *)) { - rootView.backgroundColor = [UIColor systemBackgroundColor]; - } else { - rootView.backgroundColor = [UIColor whiteColor]; - } + self.moduleName = @"ProjectName"; + // You can add your custom initial props in the dictionary below. + // They will be passed down to the ViewController used by React Native. + self.initialProps = @{}; - // SplashScreen Initialization - [RNSplashScreen show]; + bool didFinish=[super application:application didFinishLaunchingWithOptions:launchOptions]; - self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds]; - UIViewController *rootViewController = [UIViewController new]; - rootViewController.view = rootView; - self.window.rootViewController = rootViewController; - [self.window makeKeyAndVisible]; - return YES; -} - -/// This method controls whether the `concurrentRoot`feature of React18 is turned on or off. -/// -/// @see: https://reactjs.org/blog/2022/03/29/react-v18.html -/// @note: This requires to be rendering on Fabric (i.e. on the New Architecture). -/// @return: `true` if the `concurrentRoot` feture is enabled. Otherwise, it returns `false`. -- (BOOL)concurrentRootEnabled -{ - // Switch this bool to turn on and off the concurrent root - return true; -} -- (NSDictionary *)prepareInitialProps -{ - NSMutableDictionary *initProps = [NSMutableDictionary new]; -#ifdef RCT_NEW_ARCH_ENABLED - initProps[kRNConcurrentRoot] = @([self concurrentRootEnabled]); -#endif - return initProps; + [RNSplashScreen show]; // here + return didFinish; } - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge @@ -90,43 +28,14 @@ - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge #endif } -#if RCT_NEW_ARCH_ENABLED - -#pragma mark - RCTCxxBridgeDelegate - -- (std::unique_ptr)jsExecutorFactoryForBridge:(RCTBridge *)bridge -{ - _turboModuleManager = [[RCTTurboModuleManager alloc] initWithBridge:bridge - delegate:self - jsInvoker:bridge.jsCallInvoker]; - return RCTAppSetupDefaultJsExecutorFactory(bridge, _turboModuleManager); -} - -#pragma mark RCTTurboModuleManagerDelegate - -- (Class)getModuleClassFromName:(const char *)name -{ - return RCTCoreModulesClassProvider(name); -} - -- (std::shared_ptr)getTurboModule:(const std::string &)name - jsInvoker:(std::shared_ptr)jsInvoker -{ - return nullptr; -} - -- (std::shared_ptr)getTurboModule:(const std::string &)name - initParams: - (const facebook::react::ObjCTurboModule::InitParams &)params -{ - return nullptr; -} - -- (id)getModuleInstanceFromClass:(Class)moduleClass +/// This method controls whether the `concurrentRoot`feature of React18 is turned on or off. +/// +/// @see: https://reactjs.org/blog/2022/03/29/react-v18.html +/// @note: This requires to be rendering on Fabric (i.e. on the New Architecture). +/// @return: `true` if the `concurrentRoot` feature is enabled. Otherwise, it returns `false`. +- (BOOL)concurrentRootEnabled { - return RCTAppSetupDefaultModuleFromClass(moduleClass); + return true; } -#endif - @end diff --git a/ios/RNTypescriptBoilerplate/Info.plist b/ios/RNTypescriptBoilerplate/Info.plist index 4cf2960..7ecd69e 100644 --- a/ios/RNTypescriptBoilerplate/Info.plist +++ b/ios/RNTypescriptBoilerplate/Info.plist @@ -17,11 +17,11 @@ CFBundlePackageType APPL CFBundleShortVersionString - 1.0 + $(MARKETING_VERSION) CFBundleSignature ???? CFBundleVersion - 1 + $(CURRENT_PROJECT_VERSION) LSRequiresIPhoneOS NSAppTransportSecurity diff --git a/package-lock.json b/package-lock.json index fd45207..9150a40 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,7 +11,6 @@ "@freakycoder/react-native-bounceable": "1.0.3", "@freakycoder/react-native-custom-text": "0.1.2", "@freakycoder/react-native-helpers": "2.0.0", - "@react-native-async-storage/async-storage": "^1.17.9", "@react-native-masked-view/masked-view": "^0.2.7", "@react-navigation/bottom-tabs": "^6.3.2", "@react-navigation/native": "^6.0.11", @@ -24,8 +23,8 @@ "react-native-dynamic-vector-icons": "1.3.0", "react-native-gesture-handler": "^2.6.1", "react-native-localization": "^2.3.1", - "react-native-reanimated": "^2.9.1", - "react-native-safe-area-context": "^4.3.1", + "react-native-reanimated": "^2.14.4", + "react-native-safe-area-context": "^4.5.0", "react-native-screens": "^3.15.0", "react-native-splash-screen": "^3.3.0", "react-native-vector-icons": "^9.2.0", @@ -60,7 +59,7 @@ "husky": "^8.0.1", "metro-react-native-babel-preset": "^0.73.7", "prettier": "^2.7.1", - "react-native-codegen": "0.71.3", + "react-native-codegen": "0.71.5", "typescript": "^4.8.4" } }, @@ -2822,17 +2821,6 @@ "node": ">= 8" } }, - "node_modules/@react-native-async-storage/async-storage": { - "version": "1.17.9", - "resolved": "https://registry.npmjs.org/@react-native-async-storage/async-storage/-/async-storage-1.17.9.tgz", - "integrity": "sha512-HKhMvjpA5/YzNMkcY3qeWLdTtUrtJe243knHNNYe1c0IplX69hZyiw7DjFwAgxPG9+YvzHDHliqPV+mBNOv+cQ==", - "dependencies": { - "merge-options": "^3.0.4" - }, - "peerDependencies": { - "react-native": "^0.0.0-0 || 0.60 - 0.69 || 1000.0.0" - } - }, "node_modules/@react-native-community/cli": { "version": "10.1.3", "resolved": "https://registry.npmjs.org/@react-native-community/cli/-/cli-10.1.3.tgz", @@ -3415,11 +3403,6 @@ "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.41.tgz", "integrity": "sha512-ewXv/ceBaJprikMcxCmWU1FKyMAQ2X7a9Gtmzw8fcg2kIePI1crERDM818W+XYrxqdBBOdlf2rm137bU+BltCA==" }, - "node_modules/@types/invariant": { - "version": "2.2.35", - "resolved": "https://registry.npmjs.org/@types/invariant/-/invariant-2.2.35.tgz", - "integrity": "sha512-DxX1V9P8zdJPYQat1gHyY0xj3efl8gnMVjiM9iCY6y27lj+PoQWkgjt8jDqmovPqULkKVpKRg8J36iQiA+EtEg==" - }, "node_modules/@types/istanbul-lib-coverage": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", @@ -8404,25 +8387,6 @@ "node": ">=10" } }, - "node_modules/merge-options": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/merge-options/-/merge-options-3.0.4.tgz", - "integrity": "sha512-2Sug1+knBjkaMsMgf1ctR1Ujx+Ayku4EdJN4Z+C2+JzoeF7A3OZ9KM2GY0CpQS51NR61LTurMJrRKPhSs3ZRTQ==", - "dependencies": { - "is-plain-obj": "^2.1.0" - }, - "engines": { - "node": ">=10" - } - }, - "node_modules/merge-options/node_modules/is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", - "engines": { - "node": ">=8" - } - }, "node_modules/merge-stream": { "version": "2.0.0", "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==" @@ -10300,10 +10264,9 @@ } }, "node_modules/react-native-codegen": { - "version": "0.71.3", - "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.3.tgz", - "integrity": "sha512-5AvdHVU1sAaXg05i0dG664ZTaCaIFaY1znV5vNsj+wUu6MGxNEUNbDKk9dxKUkkxOyk2KZOK5uhzWL0p5H5yZQ==", - "dev": true, + "version": "0.71.5", + "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.5.tgz", + "integrity": "sha512-rfsuc0zkuUuMjFnrT55I1mDZ+pBRp2zAiRwxck3m6qeGJBGK5OV5JH66eDQ4aa+3m0of316CqrJDRzVlYufzIg==", "dependencies": { "@babel/parser": "^7.14.0", "flow-parser": "^0.185.0", @@ -10370,14 +10333,13 @@ } }, "node_modules/react-native-reanimated": { - "version": "2.9.1", - "resolved": "https://registry.npmjs.org/react-native-reanimated/-/react-native-reanimated-2.9.1.tgz", - "integrity": "sha512-309SIhDBwY4F1n6e5Mr5D1uPZm2ESIcmZsGXHUu8hpKX4oIOlZj2MilTk+kHhi05LjChoJkcpfkstotCJmPRPg==", + "version": "2.14.4", + "resolved": "https://registry.npmjs.org/react-native-reanimated/-/react-native-reanimated-2.14.4.tgz", + "integrity": "sha512-DquSbl7P8j4SAmc+kRdd75Ianm8G+IYQ9T4AQ6lrpLVeDkhZmjWI0wkutKWnp6L7c5XNVUrFDUf69dwETLCItQ==", "dependencies": { - "@babel/plugin-proposal-export-namespace-from": "^7.17.12", "@babel/plugin-transform-object-assign": "^7.16.7", "@babel/preset-typescript": "^7.16.7", - "@types/invariant": "^2.2.35", + "convert-source-map": "^1.7.0", "invariant": "^2.2.4", "lodash.isequal": "^4.5.0", "setimmediate": "^1.0.5", @@ -10390,9 +10352,9 @@ } }, "node_modules/react-native-safe-area-context": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.3.1.tgz", - "integrity": "sha512-cEr7fknJCToTrSyDCVNg0GRdRMhyLeQa2NZwVCuzEQcWedOw/59ExomjmzCE4rxrKXs6OJbyfNtFRNyewDaHuA==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.5.0.tgz", + "integrity": "sha512-0WORnk9SkREGUg2V7jHZbuN5x4vcxj/1B0QOcXJjdYWrzZHgLcUzYWWIUecUPJh747Mwjt/42RZDOaFn3L8kPQ==", "peerDependencies": { "react": "*", "react-native": "*" @@ -10491,17 +10453,6 @@ "node": ">=10" } }, - "node_modules/react-native/node_modules/react-native-codegen": { - "version": "0.71.5", - "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.5.tgz", - "integrity": "sha512-rfsuc0zkuUuMjFnrT55I1mDZ+pBRp2zAiRwxck3m6qeGJBGK5OV5JH66eDQ4aa+3m0of316CqrJDRzVlYufzIg==", - "dependencies": { - "@babel/parser": "^7.14.0", - "flow-parser": "^0.185.0", - "jscodeshift": "^0.13.1", - "nullthrows": "^1.1.1" - } - }, "node_modules/react-native/node_modules/ws": { "version": "6.2.2", "integrity": "sha512-zmhltoSR8u1cnDsD43TX59mzoMZsLKqUweyYBAIvTngR3shc0W6aOZylZmq/7hqyVxPdi+5Ud2QInblgyE72fw==", @@ -14558,14 +14509,6 @@ "fastq": "^1.6.0" } }, - "@react-native-async-storage/async-storage": { - "version": "1.17.9", - "resolved": "https://registry.npmjs.org/@react-native-async-storage/async-storage/-/async-storage-1.17.9.tgz", - "integrity": "sha512-HKhMvjpA5/YzNMkcY3qeWLdTtUrtJe243knHNNYe1c0IplX69hZyiw7DjFwAgxPG9+YvzHDHliqPV+mBNOv+cQ==", - "requires": { - "merge-options": "^3.0.4" - } - }, "@react-native-community/cli": { "version": "10.1.3", "resolved": "https://registry.npmjs.org/@react-native-community/cli/-/cli-10.1.3.tgz", @@ -15071,11 +15014,6 @@ "resolved": "https://registry.npmjs.org/@types/hammerjs/-/hammerjs-2.0.41.tgz", "integrity": "sha512-ewXv/ceBaJprikMcxCmWU1FKyMAQ2X7a9Gtmzw8fcg2kIePI1crERDM818W+XYrxqdBBOdlf2rm137bU+BltCA==" }, - "@types/invariant": { - "version": "2.2.35", - "resolved": "https://registry.npmjs.org/@types/invariant/-/invariant-2.2.35.tgz", - "integrity": "sha512-DxX1V9P8zdJPYQat1gHyY0xj3efl8gnMVjiM9iCY6y27lj+PoQWkgjt8jDqmovPqULkKVpKRg8J36iQiA+EtEg==" - }, "@types/istanbul-lib-coverage": { "version": "2.0.4", "resolved": "https://registry.npmjs.org/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz", @@ -18728,21 +18666,6 @@ } } }, - "merge-options": { - "version": "3.0.4", - "resolved": "https://registry.npmjs.org/merge-options/-/merge-options-3.0.4.tgz", - "integrity": "sha512-2Sug1+knBjkaMsMgf1ctR1Ujx+Ayku4EdJN4Z+C2+JzoeF7A3OZ9KM2GY0CpQS51NR61LTurMJrRKPhSs3ZRTQ==", - "requires": { - "is-plain-obj": "^2.1.0" - }, - "dependencies": { - "is-plain-obj": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", - "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==" - } - } - }, "merge-stream": { "version": "2.0.0", "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==" @@ -20232,17 +20155,6 @@ "ws": "^6.2.2" }, "dependencies": { - "react-native-codegen": { - "version": "0.71.5", - "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.5.tgz", - "integrity": "sha512-rfsuc0zkuUuMjFnrT55I1mDZ+pBRp2zAiRwxck3m6qeGJBGK5OV5JH66eDQ4aa+3m0of316CqrJDRzVlYufzIg==", - "requires": { - "@babel/parser": "^7.14.0", - "flow-parser": "^0.185.0", - "jscodeshift": "^0.13.1", - "nullthrows": "^1.1.1" - } - }, "ws": { "version": "6.2.2", "integrity": "sha512-zmhltoSR8u1cnDsD43TX59mzoMZsLKqUweyYBAIvTngR3shc0W6aOZylZmq/7hqyVxPdi+5Ud2QInblgyE72fw==", @@ -20253,10 +20165,9 @@ } }, "react-native-codegen": { - "version": "0.71.3", - "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.3.tgz", - "integrity": "sha512-5AvdHVU1sAaXg05i0dG664ZTaCaIFaY1znV5vNsj+wUu6MGxNEUNbDKk9dxKUkkxOyk2KZOK5uhzWL0p5H5yZQ==", - "dev": true, + "version": "0.71.5", + "resolved": "https://registry.npmjs.org/react-native-codegen/-/react-native-codegen-0.71.5.tgz", + "integrity": "sha512-rfsuc0zkuUuMjFnrT55I1mDZ+pBRp2zAiRwxck3m6qeGJBGK5OV5JH66eDQ4aa+3m0of316CqrJDRzVlYufzIg==", "requires": { "@babel/parser": "^7.14.0", "flow-parser": "^0.185.0", @@ -20308,14 +20219,13 @@ } }, "react-native-reanimated": { - "version": "2.9.1", - "resolved": "https://registry.npmjs.org/react-native-reanimated/-/react-native-reanimated-2.9.1.tgz", - "integrity": "sha512-309SIhDBwY4F1n6e5Mr5D1uPZm2ESIcmZsGXHUu8hpKX4oIOlZj2MilTk+kHhi05LjChoJkcpfkstotCJmPRPg==", + "version": "2.14.4", + "resolved": "https://registry.npmjs.org/react-native-reanimated/-/react-native-reanimated-2.14.4.tgz", + "integrity": "sha512-DquSbl7P8j4SAmc+kRdd75Ianm8G+IYQ9T4AQ6lrpLVeDkhZmjWI0wkutKWnp6L7c5XNVUrFDUf69dwETLCItQ==", "requires": { - "@babel/plugin-proposal-export-namespace-from": "^7.17.12", "@babel/plugin-transform-object-assign": "^7.16.7", "@babel/preset-typescript": "^7.16.7", - "@types/invariant": "^2.2.35", + "convert-source-map": "^1.7.0", "invariant": "^2.2.4", "lodash.isequal": "^4.5.0", "setimmediate": "^1.0.5", @@ -20323,9 +20233,9 @@ } }, "react-native-safe-area-context": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.3.1.tgz", - "integrity": "sha512-cEr7fknJCToTrSyDCVNg0GRdRMhyLeQa2NZwVCuzEQcWedOw/59ExomjmzCE4rxrKXs6OJbyfNtFRNyewDaHuA==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/react-native-safe-area-context/-/react-native-safe-area-context-4.5.0.tgz", + "integrity": "sha512-0WORnk9SkREGUg2V7jHZbuN5x4vcxj/1B0QOcXJjdYWrzZHgLcUzYWWIUecUPJh747Mwjt/42RZDOaFn3L8kPQ==", "requires": {} }, "react-native-screens": { diff --git a/package.json b/package.json index 73e3dda..f67fe45 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,6 @@ "@freakycoder/react-native-bounceable": "1.0.3", "@freakycoder/react-native-custom-text": "0.1.2", "@freakycoder/react-native-helpers": "2.0.0", - "@react-native-async-storage/async-storage": "^1.17.9", "@react-native-masked-view/masked-view": "^0.2.7", "@react-navigation/bottom-tabs": "^6.3.2", "@react-navigation/native": "^6.0.11", @@ -19,8 +18,8 @@ "react-native-dynamic-vector-icons": "1.3.0", "react-native-gesture-handler": "^2.6.1", "react-native-localization": "^2.3.1", - "react-native-reanimated": "^2.9.1", - "react-native-safe-area-context": "^4.3.1", + "react-native-reanimated": "^2.14.4", + "react-native-safe-area-context": "^4.5.0", "react-native-screens": "^3.15.0", "react-native-splash-screen": "^3.3.0", "react-native-vector-icons": "^9.2.0", @@ -55,7 +54,7 @@ "husky": "^8.0.1", "metro-react-native-babel-preset": "^0.73.7", "prettier": "^2.7.1", - "react-native-codegen": "0.71.3", + "react-native-codegen": "0.71.5", "typescript": "^4.8.4" }, "scripts": { diff --git a/src/navigation/index.tsx b/src/navigation/index.tsx index b3580b3..eb9c17f 100644 --- a/src/navigation/index.tsx +++ b/src/navigation/index.tsx @@ -1,6 +1,6 @@ import React from "react"; import { useColorScheme } from "react-native"; -import Icon from "react-native-dynamic-vector-icons"; +import Icon, { IconType } from "react-native-dynamic-vector-icons"; import { createStackNavigator } from "@react-navigation/stack"; import { NavigationContainer } from "@react-navigation/native"; import { isReadyRef, navigationRef } from "react-navigation-helpers"; @@ -9,7 +9,7 @@ import { createBottomTabNavigator } from "@react-navigation/bottom-tabs"; * ? Local & Shared Imports */ import { SCREENS } from "@shared-constants"; -import { LightTheme, DarkTheme, palette } from "@theme/themes"; +import { DarkTheme, LightTheme, palette } from "@theme/themes"; // ? Screens import HomeScreen from "@screens/home/HomeScreen"; import SearchScreen from "@screens/search/SearchScreen"; @@ -53,7 +53,14 @@ const Navigation = () => { iconName = focused ? "home" : "home-outline"; break; } - return ; + return ( + + ); }; const renderTabNavigation = () => { diff --git a/src/screens/home/HomeScreen.tsx b/src/screens/home/HomeScreen.tsx index a9c549d..7788eff 100644 --- a/src/screens/home/HomeScreen.tsx +++ b/src/screens/home/HomeScreen.tsx @@ -1,7 +1,7 @@ import React, { useMemo } from "react"; -import { View, FlatList, Image } from "react-native"; +import { FlatList, Image, View } from "react-native"; import { useTheme } from "@react-navigation/native"; -import Icon from "react-native-dynamic-vector-icons"; +import Icon, { IconType } from "react-native-dynamic-vector-icons"; import { SafeAreaView } from "react-native-safe-area-context"; import * as NavigationService from "react-navigation-helpers"; import RNBounceable from "@freakycoder/react-native-bounceable"; @@ -39,7 +39,12 @@ const HomeScreen: React.FC = () => { const MenuButton = () => ( - + ); diff --git a/tsconfig.json b/tsconfig.json index b175970..3d3ce41 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -42,6 +42,7 @@ "@local-storage": ["./services/local-storage"] } }, + "extends": "@tsconfig/react-native/tsconfig.json", "exclude": [ "node_modules", "babel.config.js",