react-native-tvos 0.83.0-0rc0 → 0.83.0-0rc2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (57) hide show
  1. package/Libraries/Core/ReactNativeVersion.js +1 -1
  2. package/React/Base/RCTVersion.m +1 -1
  3. package/React/CoreModules/React-CoreModules.podspec +1 -0
  4. package/React/FBReactNativeSpec/FBReactNativeSpecJSI.h +16 -0
  5. package/React/Runtime/React-RCTRuntime.podspec +1 -0
  6. package/ReactAndroid/gradle.properties +1 -1
  7. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlags.kt +13 -1
  8. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsCxxAccessor.kt +21 -1
  9. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsCxxInterop.kt +5 -1
  10. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsDefaults.kt +8 -4
  11. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsLocalAccessor.kt +23 -1
  12. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsOverrides_RNOSS_Canary_Android.kt +3 -1
  13. package/ReactAndroid/src/main/java/com/facebook/react/internal/featureflags/ReactNativeFeatureFlagsProvider.kt +5 -1
  14. package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +1 -1
  15. package/ReactAndroid/src/main/jni/CMakeLists.txt +5 -0
  16. package/ReactAndroid/src/main/jni/react/featureflags/JReactNativeFeatureFlagsCxxInterop.cpp +29 -1
  17. package/ReactAndroid/src/main/jni/react/featureflags/JReactNativeFeatureFlagsCxxInterop.h +7 -1
  18. package/ReactCommon/React-Fabric.podspec +8 -2
  19. package/ReactCommon/cxxreact/React-cxxreact.podspec +1 -0
  20. package/ReactCommon/cxxreact/ReactNativeVersion.h +1 -1
  21. package/ReactCommon/jsiexecutor/React-jsiexecutor.podspec +1 -0
  22. package/ReactCommon/jsinspector-modern/HostAgent.cpp +33 -0
  23. package/ReactCommon/jsinspector-modern/HostAgent.h +6 -0
  24. package/ReactCommon/jsinspector-modern/HostTarget.h +5 -0
  25. package/ReactCommon/jsinspector-modern/InspectorFlags.cpp +6 -0
  26. package/ReactCommon/jsinspector-modern/InspectorFlags.h +7 -0
  27. package/ReactCommon/jsinspector-modern/InspectorInterfaces.cpp +37 -0
  28. package/ReactCommon/jsinspector-modern/InspectorInterfaces.h +12 -1
  29. package/ReactCommon/jsinspector-modern/TracingAgent.cpp +11 -1
  30. package/ReactCommon/jsinspector-modern/tracing/React-jsinspectortracing.podspec +4 -0
  31. package/ReactCommon/jsitooling/React-jsitooling.podspec +1 -0
  32. package/ReactCommon/react/featureflags/ReactNativeFeatureFlags.cpp +9 -1
  33. package/ReactCommon/react/featureflags/ReactNativeFeatureFlags.h +11 -1
  34. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsAccessor.cpp +90 -54
  35. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsAccessor.h +6 -2
  36. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsDefaults.h +12 -4
  37. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsDynamicProvider.h +19 -1
  38. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsOverridesOSSCanary.h +5 -1
  39. package/ReactCommon/react/featureflags/ReactNativeFeatureFlagsProvider.h +3 -1
  40. package/ReactCommon/react/nativemodule/defaults/CMakeLists.txt +1 -0
  41. package/ReactCommon/react/nativemodule/defaults/DefaultTurboModules.cpp +7 -0
  42. package/ReactCommon/react/nativemodule/defaults/React-defaultsnativemodule.podspec +5 -1
  43. package/ReactCommon/react/nativemodule/featureflags/NativeReactNativeFeatureFlags.cpp +11 -1
  44. package/ReactCommon/react/nativemodule/featureflags/NativeReactNativeFeatureFlags.h +5 -1
  45. package/ReactCommon/react/nativemodule/intersectionobserver/NativeIntersectionObserver.h +4 -0
  46. package/ReactCommon/react/nativemodule/intersectionobserver/React-intersectionobservernativemodule.podspec +66 -0
  47. package/ReactCommon/react/utils/React-utils.podspec +3 -1
  48. package/package.json +9 -8
  49. package/scripts/cocoapods/rncore.rb +20 -8
  50. package/scripts/cocoapods/rndependencies.rb +20 -6
  51. package/scripts/react_native_pods.rb +1 -0
  52. package/sdks/.hermesv1version +1 -0
  53. package/sdks/hermes-engine/hermes-utils.rb +18 -7
  54. package/sdks/hermes-engine/version.properties +1 -1
  55. package/src/private/featureflags/ReactNativeFeatureFlags.js +14 -4
  56. package/src/private/featureflags/specs/NativeReactNativeFeatureFlags.js +3 -1
  57. package/src/private/setup/setUpDefaultReactNativeEnvironment.js +6 -0
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<db8626cf78a3ed226bbbe6bf20cc03a2>>
7
+ * @generated SignedSource<<1b2061068e0d6c9ca362ceddd97862da>>
8
8
  */
9
9
 
10
10
  /**
@@ -35,6 +35,10 @@ class ReactNativeFeatureFlagsOverridesOSSCanary : public ReactNativeFeatureFlags
35
35
  return true;
36
36
  }
37
37
 
38
+ bool enableIntersectionObserverByDefault() override {
39
+ return true;
40
+ }
41
+
38
42
  bool useNativeViewConfigsInBridgelessMode() override {
39
43
  return true;
40
44
  }
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<5dcaab263795b1605da54dbbb617264f>>
7
+ * @generated SignedSource<<06c6740fe7d613f235ae791da750bd52>>
8
8
  */
9
9
 
10
10
  /**
@@ -55,6 +55,7 @@ class ReactNativeFeatureFlagsProvider {
55
55
  virtual bool enableImmediateUpdateModeForContentOffsetChanges() = 0;
56
56
  virtual bool enableImperativeFocus() = 0;
57
57
  virtual bool enableInteropViewManagerClassLookUpOptimizationIOS() = 0;
58
+ virtual bool enableIntersectionObserverByDefault() = 0;
58
59
  virtual bool enableKeyEvents() = 0;
59
60
  virtual bool enableLayoutAnimationsOnAndroid() = 0;
60
61
  virtual bool enableLayoutAnimationsOnIOS() = 0;
@@ -79,6 +80,7 @@ class ReactNativeFeatureFlagsProvider {
79
80
  virtual bool enableVirtualViewWindowFocusDetection() = 0;
80
81
  virtual bool enableWebPerformanceAPIsByDefault() = 0;
81
82
  virtual bool fixMappingOfEventPrioritiesBetweenFabricAndReact() = 0;
83
+ virtual bool fuseboxAssertSingleHostState() = 0;
82
84
  virtual bool fuseboxEnabledRelease() = 0;
83
85
  virtual bool fuseboxNetworkInspectionEnabled() = 0;
84
86
  virtual bool hideOffscreenVirtualViewsOnIOS() = 0;
@@ -21,6 +21,7 @@ target_link_libraries(react_nativemodule_defaults
21
21
  react_nativemodule_featureflags
22
22
  react_nativemodule_microtasks
23
23
  react_nativemodule_idlecallbacks
24
+ react_nativemodule_intersectionobserver
24
25
  react_nativemodule_webperformance
25
26
  )
26
27
  target_compile_reactnative_options(react_nativemodule_defaults PRIVATE)
@@ -10,6 +10,7 @@
10
10
  #include <react/nativemodule/dom/NativeDOM.h>
11
11
  #include <react/nativemodule/featureflags/NativeReactNativeFeatureFlags.h>
12
12
  #include <react/nativemodule/idlecallbacks/NativeIdleCallbacks.h>
13
+ #include <react/nativemodule/intersectionobserver/NativeIntersectionObserver.h>
13
14
  #include <react/nativemodule/microtasks/NativeMicrotasks.h>
14
15
  #include <react/nativemodule/webperformance/NativePerformance.h>
15
16
 
@@ -44,6 +45,12 @@ namespace facebook::react {
44
45
  }
45
46
  }
46
47
 
48
+ if (ReactNativeFeatureFlags::enableIntersectionObserverByDefault()) {
49
+ if (name == NativeIntersectionObserver::kModuleName) {
50
+ return std::make_shared<NativeIntersectionObserver>(jsInvoker);
51
+ }
52
+ }
53
+
47
54
  #ifdef REACT_NATIVE_DEBUGGER_ENABLED_DEVONLY
48
55
  if (name == DevToolsRuntimeSettingsModule::kModuleName) {
49
56
  return std::make_shared<DevToolsRuntimeSettingsModule>(jsInvoker);
@@ -16,7 +16,9 @@ else
16
16
  source[:tag] = "v#{version}"
17
17
  end
18
18
 
19
- header_search_paths = []
19
+ header_search_paths = [
20
+ "\"$(PODS_ROOT)/Headers/Private/Yoga\"",
21
+ ]
20
22
 
21
23
  if ENV['USE_FRAMEWORKS']
22
24
  header_search_paths << "\"$(PODS_TARGET_SRCROOT)/../../..\"" # this is needed to allow the defaultsnativemodule to access its own files
@@ -40,6 +42,7 @@ Pod::Spec.new do |s|
40
42
 
41
43
  resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_defaultsnativemodule")
42
44
 
45
+ s.dependency "Yoga"
43
46
  s.dependency "React-jsi"
44
47
  s.dependency "React-jsiexecutor"
45
48
  depend_on_js_engine(s)
@@ -49,6 +52,7 @@ Pod::Spec.new do |s|
49
52
  s.dependency "React-domnativemodule"
50
53
  s.dependency "React-microtasksnativemodule"
51
54
  s.dependency "React-idlecallbacksnativemodule"
55
+ s.dependency "React-intersectionobservernativemodule"
52
56
  s.dependency "React-webperformancenativemodule"
53
57
  add_dependency(s, "React-RCTFBReactNativeSpec")
54
58
  add_dependency(s, "React-featureflags")
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<6bd64914d0e2f0c727490a420496fbb0>>
7
+ * @generated SignedSource<<3f6cc9604905bb29a9524a97eaa294bd>>
8
8
  */
9
9
 
10
10
  /**
@@ -194,6 +194,11 @@ bool NativeReactNativeFeatureFlags::enableInteropViewManagerClassLookUpOptimizat
194
194
  return ReactNativeFeatureFlags::enableInteropViewManagerClassLookUpOptimizationIOS();
195
195
  }
196
196
 
197
+ bool NativeReactNativeFeatureFlags::enableIntersectionObserverByDefault(
198
+ jsi::Runtime& /*runtime*/) {
199
+ return ReactNativeFeatureFlags::enableIntersectionObserverByDefault();
200
+ }
201
+
197
202
  bool NativeReactNativeFeatureFlags::enableKeyEvents(
198
203
  jsi::Runtime& /*runtime*/) {
199
204
  return ReactNativeFeatureFlags::enableKeyEvents();
@@ -314,6 +319,11 @@ bool NativeReactNativeFeatureFlags::fixMappingOfEventPrioritiesBetweenFabricAndR
314
319
  return ReactNativeFeatureFlags::fixMappingOfEventPrioritiesBetweenFabricAndReact();
315
320
  }
316
321
 
322
+ bool NativeReactNativeFeatureFlags::fuseboxAssertSingleHostState(
323
+ jsi::Runtime& /*runtime*/) {
324
+ return ReactNativeFeatureFlags::fuseboxAssertSingleHostState();
325
+ }
326
+
317
327
  bool NativeReactNativeFeatureFlags::fuseboxEnabledRelease(
318
328
  jsi::Runtime& /*runtime*/) {
319
329
  return ReactNativeFeatureFlags::fuseboxEnabledRelease();
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<99624bd7682ad34476ac395e8acc43c7>>
7
+ * @generated SignedSource<<dece70d27e5d2e4d052ca4e158c4b968>>
8
8
  */
9
9
 
10
10
  /**
@@ -96,6 +96,8 @@ class NativeReactNativeFeatureFlags
96
96
 
97
97
  bool enableInteropViewManagerClassLookUpOptimizationIOS(jsi::Runtime& runtime);
98
98
 
99
+ bool enableIntersectionObserverByDefault(jsi::Runtime& runtime);
100
+
99
101
  bool enableKeyEvents(jsi::Runtime& runtime);
100
102
 
101
103
  bool enableLayoutAnimationsOnAndroid(jsi::Runtime& runtime);
@@ -144,6 +146,8 @@ class NativeReactNativeFeatureFlags
144
146
 
145
147
  bool fixMappingOfEventPrioritiesBetweenFabricAndReact(jsi::Runtime& runtime);
146
148
 
149
+ bool fuseboxAssertSingleHostState(jsi::Runtime& runtime);
150
+
147
151
  bool fuseboxEnabledRelease(jsi::Runtime& runtime);
148
152
 
149
153
  bool fuseboxNetworkInspectionEnabled(jsi::Runtime& runtime);
@@ -7,7 +7,11 @@
7
7
 
8
8
  #pragma once
9
9
 
10
+ #if __has_include("FBReactNativeSpecJSI.h") // CocoaPod headers on Apple
11
+ #include "FBReactNativeSpecJSI.h"
12
+ #else
10
13
  #include <FBReactNativeSpec/FBReactNativeSpecJSI.h>
14
+ #endif
11
15
  #include <react/renderer/bridging/bridging.h>
12
16
  #include <react/renderer/observers/intersection/IntersectionObserverManager.h>
13
17
  #include <optional>
@@ -0,0 +1,66 @@
1
+ # Copyright (c) Meta Platforms, Inc. and affiliates.
2
+ #
3
+ # This source code is licensed under the MIT license found in the
4
+ # LICENSE file in the root directory of this source tree.
5
+
6
+ require "json"
7
+
8
+ package = JSON.parse(File.read(File.join(__dir__, "..", "..", "..", "..", "package.json")))
9
+ version = package['version']
10
+
11
+ source = { :git => 'https://github.com/facebook/react-native.git' }
12
+ if version == '1000.0.0'
13
+ # This is an unpublished version, use the latest commit hash of the react-native repo, which we're presumably in.
14
+ source[:commit] = `git rev-parse HEAD`.strip if system("git rev-parse --git-dir > /dev/null 2>&1")
15
+ else
16
+ source[:tag] = "v#{version}"
17
+ end
18
+
19
+ header_search_paths = [
20
+ "\"$(PODS_ROOT)/Headers/Private/Yoga\"",
21
+ ]
22
+
23
+ if ENV['USE_FRAMEWORKS']
24
+ header_search_paths << "\"$(PODS_TARGET_SRCROOT)/../../..\"" # this is needed to allow the module access its own files
25
+ end
26
+
27
+ Pod::Spec.new do |s|
28
+ s.name = "React-intersectionobservernativemodule"
29
+ s.version = version
30
+ s.summary = "React Native intersection observer native module"
31
+ s.homepage = "https://reactnative.dev/"
32
+ s.license = package["license"]
33
+ s.author = "Meta Platforms, Inc. and its affiliates"
34
+ s.platforms = min_supported_versions
35
+ s.source = source
36
+ s.source_files = podspec_sources("*.{cpp,h}", "*.h")
37
+ s.header_dir = "react/nativemodule/intersectionobserver"
38
+ s.pod_target_xcconfig = { "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
39
+ "HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
40
+ "OTHER_CFLAGS" => "$(inherited)",
41
+ "DEFINES_MODULE" => "YES" }
42
+
43
+ if ENV['USE_FRAMEWORKS']
44
+ s.module_name = "intersectionobservernativemodule"
45
+ s.header_mappings_dir = "../.."
46
+ end
47
+
48
+ s.dependency "Yoga"
49
+ s.dependency "React-jsi"
50
+ s.dependency "React-jsiexecutor"
51
+ s.dependency "React-cxxreact"
52
+
53
+ depend_on_js_engine(s)
54
+ add_rn_third_party_dependencies(s)
55
+ add_rncore_dependency(s)
56
+
57
+ s.dependency "ReactCommon/turbomodule/core"
58
+
59
+ s.dependency "React-Fabric"
60
+ s.dependency "React-Fabric/bridging"
61
+ s.dependency "React-runtimescheduler"
62
+ add_dependency(s, "React-RCTFBReactNativeSpec")
63
+ add_dependency(s, "React-runtimeexecutor", :additional_framework_paths => ["platform/ios"])
64
+ add_dependency(s, "React-graphics", :additional_framework_paths => ["react/renderer/graphics/platform/ios"])
65
+
66
+ end
@@ -47,7 +47,9 @@ Pod::Spec.new do |s|
47
47
 
48
48
  s.dependency "React-jsi", version
49
49
 
50
- depend_on_js_engine(s)
50
+ if use_hermes()
51
+ s.dependency "hermes-engine"
52
+ end
51
53
  add_rn_third_party_dependencies(s)
52
54
  add_rncore_dependency(s)
53
55
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-tvos",
3
- "version": "0.83.0-0rc0",
3
+ "version": "0.83.0-0rc2",
4
4
  "description": "A framework for building native apps using React",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -133,6 +133,7 @@
133
133
  "scripts/xcode/ccache.conf",
134
134
  "scripts/xcode/with-environment.sh",
135
135
  "sdks/.hermesversion",
136
+ "sdks/.hermesv1version",
136
137
  "sdks/hermes-engine",
137
138
  "sdks/hermesc",
138
139
  "settings.gradle.kts",
@@ -163,12 +164,12 @@
163
164
  },
164
165
  "dependencies": {
165
166
  "@jest/create-cache-key-function": "^29.7.0",
166
- "@react-native/assets-registry": "0.83.0-rc.0",
167
- "@react-native/codegen": "0.83.0-rc.0",
168
- "@react-native/community-cli-plugin": "0.83.0-rc.0",
169
- "@react-native/gradle-plugin": "0.83.0-rc.0",
170
- "@react-native/js-polyfills": "0.83.0-rc.0",
171
- "@react-native/normalize-colors": "0.83.0-rc.0",
167
+ "@react-native/assets-registry": "0.83.0-rc.2",
168
+ "@react-native/codegen": "0.83.0-rc.2",
169
+ "@react-native/community-cli-plugin": "0.83.0-rc.2",
170
+ "@react-native/gradle-plugin": "0.83.0-rc.2",
171
+ "@react-native/js-polyfills": "0.83.0-rc.2",
172
+ "@react-native/normalize-colors": "0.83.0-rc.2",
172
173
  "abort-controller": "^3.0.0",
173
174
  "anser": "^1.4.9",
174
175
  "ansi-regex": "^5.0.0",
@@ -196,7 +197,7 @@
196
197
  "whatwg-fetch": "^3.0.0",
197
198
  "ws": "^7.5.10",
198
199
  "yargs": "^17.6.2",
199
- "@react-native-tvos/virtualized-lists": "0.83.0-0rc0"
200
+ "@react-native-tvos/virtualized-lists": "0.83.0-0rc2"
200
201
  },
201
202
  "codegenConfig": {
202
203
  "libraries": [
@@ -273,9 +273,10 @@ class ReactNativeCoreUtils
273
273
  return if dsym_bundles.empty?
274
274
 
275
275
  # Define source path mappings - from absolute build paths to relative framework paths
276
+ # Expand the path relative to the installation root (project root, parent of ios/)
277
+ react_native_absolute_path = File.expand_path(@@react_native_path, Pod::Config.instance.installation_root)
276
278
  mappings = [
277
- # Make sure to make react_native_path absolute
278
- ["/Users/runner/work/react-native/react-native/packages/react-native", "#{File.expand_path(@@react_native_path)}"],
279
+ ["/Users/runner/work/react-native/react-native/packages/react-native", react_native_absolute_path],
279
280
  ]
280
281
 
281
282
  dsym_bundles.each do |dsym_path| begin
@@ -348,23 +349,34 @@ class ReactNativeCoreUtils
348
349
  return "#{maven_repo_url}/#{group}/react-native-artifacts/#{version}/react-native-artifacts-#{version}-reactnative-core-#{dsyms ? "dSYM-" : ""}#{build_type.to_s}.tar.gz"
349
350
  end
350
351
 
352
+ def self.read_nightly_tarball_xml(xml_url)
353
+ xml_file_path = "#{artifacts_dir()}/rncore-ios.xml"
354
+ unless File.exist?(xml_file_path)
355
+ tmp_file = "#{artifacts_dir()}/rncore-ios.xml.download"
356
+ `mkdir -p "#{artifacts_dir()}" && curl "#{xml_url}" -Lo "#{tmp_file}" && mv "#{tmp_file}" "#{xml_file_path}"`
357
+ end
358
+ return File.read(xml_file_path)
359
+ end
360
+
351
361
  def self.nightly_tarball_url(version, configuration, dsyms = false)
352
362
  artefact_coordinate = "react-native-artifacts"
353
363
  artefact_name = "reactnative-core-#{dsyms ? "dSYM-" : ""}#{configuration ? configuration : "debug"}.tar.gz"
354
364
  xml_url = "https://central.sonatype.com/repository/maven-snapshots/com/facebook/react/#{artefact_coordinate}/#{version}-SNAPSHOT/maven-metadata.xml"
355
365
 
356
- response = Net::HTTP.get_response(URI(xml_url))
357
- if response.is_a?(Net::HTTPSuccess)
358
- xml = REXML::Document.new(response.body)
366
+ # response = Net::HTTP.get_response(URI(xml_url))
367
+ # if response.is_a?(Net::HTTPSuccess)
368
+ # xml = REXML::Document.new(response.body)
369
+ xml_text = read_nightly_tarball_xml(xml_url)
370
+ xml = REXML::Document.new(xml_text)
359
371
  timestamp = xml.elements['metadata/versioning/snapshot/timestamp'].text
360
372
  build_number = xml.elements['metadata/versioning/snapshot/buildNumber'].text
361
373
  full_version = "#{version}-#{timestamp}-#{build_number}"
362
374
 
363
375
  final_url = "https://central.sonatype.com/repository/maven-snapshots/com/facebook/react/#{artefact_coordinate}/#{version}-SNAPSHOT/#{artefact_coordinate}-#{full_version}-#{artefact_name}"
364
376
  return final_url
365
- else
366
- return ""
367
- end
377
+ # else
378
+ # return ""
379
+ # end
368
380
  end
369
381
 
370
382
  def self.download_stable_rncore(react_native_path, version, configuration, dsyms = false)
@@ -177,23 +177,34 @@ class ReactNativeDependenciesUtils
177
177
  return "#{maven_repo_url}/#{group}/react-native-artifacts/#{version}/react-native-artifacts-#{version}-reactnative-dependencies-#{build_type.to_s}.tar.gz"
178
178
  end
179
179
 
180
+ def self.read_nightly_tarball_xml(xml_url)
181
+ xml_file_path = "#{artifacts_dir()}/rndeps-ios.xml"
182
+ unless File.exist?(xml_file_path)
183
+ tmp_file = "#{artifacts_dir()}/rndeps-ios.xml.download"
184
+ `mkdir -p "#{artifacts_dir()}" && curl "#{xml_url}" -Lo "#{tmp_file}" && mv "#{tmp_file}" "#{xml_file_path}"`
185
+ end
186
+ return File.read(xml_file_path)
187
+ end
188
+
180
189
  def self.nightly_tarball_url(version, build_type)
181
190
  artifact_coordinate = "react-native-artifacts"
182
191
  artifact_name = "reactnative-dependencies-#{build_type.to_s}.tar.gz"
183
192
  xml_url = "https://central.sonatype.com/repository/maven-snapshots/com/facebook/react/#{artifact_coordinate}/#{version}-SNAPSHOT/maven-metadata.xml"
193
+ xml_text = read_nightly_tarball_xml(xml_url)
184
194
 
185
- response = Net::HTTP.get_response(URI(xml_url))
186
- if response.is_a?(Net::HTTPSuccess)
187
- xml = REXML::Document.new(response.body)
195
+ # response = Net::HTTP.get_response(URI(xml_url))
196
+ # if response.is_a?(Net::HTTPSuccess)
197
+ # xml = REXML::Document.new(response.body)
198
+ xml = REXML::Document.new(xml_text)
188
199
  timestamp = xml.elements['metadata/versioning/snapshot/timestamp'].text
189
200
  build_number = xml.elements['metadata/versioning/snapshot/buildNumber'].text
190
201
  full_version = "#{version}-#{timestamp}-#{build_number}"
191
202
 
192
203
  final_url = "https://central.sonatype.com/repository/maven-snapshots/com/facebook/react/#{artifact_coordinate}/#{version}-SNAPSHOT/#{artifact_coordinate}-#{full_version}-#{artifact_name}"
193
204
  return final_url
194
- else
195
- return ""
196
- end
205
+ # else
206
+ # return ""
207
+ # end
197
208
  end
198
209
 
199
210
  def self.download_nightly_rndeps(react_native_path, version, configuration)
@@ -262,6 +273,9 @@ class ReactNativeDependenciesUtils
262
273
  def self.artifact_exists(tarball_url)
263
274
  # -L is used to follow redirects, useful for the nightlies
264
275
  # I also needed to wrap the url in quotes to avoid escaping & and ?.
276
+ if ENV['RNTV_TESTONLY_LOCAL_RNCORE_REPOSITORY'] != nil && ENV['RNTV_TESTONLY_LOCAL_RNCORE_REPOSITORY'] != ""
277
+ return true
278
+ end
265
279
  return (`curl -o /dev/null --silent -Iw '%{http_code}' -L "#{tarball_url}"` == "200")
266
280
  end
267
281
 
@@ -144,6 +144,7 @@ def use_react_native! (
144
144
  pod 'React-featureflagsnativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/featureflags"
145
145
  pod 'React-microtasksnativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/microtasks"
146
146
  pod 'React-idlecallbacksnativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/idlecallbacks"
147
+ pod 'React-intersectionobservernativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/intersectionobserver"
147
148
  pod 'React-webperformancenativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/webperformance"
148
149
  pod 'React-domnativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/dom"
149
150
  pod 'React-defaultsnativemodule', :path => "#{prefix}/ReactCommon/react/nativemodule/defaults"
@@ -0,0 +1 @@
1
+ hermes-v250829098.0.3
@@ -260,25 +260,36 @@ def download_hermes_tarball(react_native_path, tarball_url, version, configurati
260
260
  return destination_path
261
261
  end
262
262
 
263
+ def read_nightly_tarball_xml(xml_url)
264
+ xml_file_path = "#{artifacts_dir()}/hermes-ios.xml"
265
+ unless File.exist?(xml_file_path)
266
+ tmp_file = "#{artifacts_dir()}/hermes-ios.xml.download"
267
+ `mkdir -p "#{artifacts_dir()}" && curl "#{xml_url}" -Lo "#{tmp_file}" && mv "#{tmp_file}" "#{xml_file_path}"`
268
+ end
269
+ return File.read(xml_file_path)
270
+ end
271
+
263
272
  def nightly_tarball_url(version)
264
273
  artifact_coordinate = "hermes-ios"
265
274
  artifact_name = "hermes-ios-debug.tar.gz"
266
275
  namespace = "com/facebook/hermes"
267
276
 
268
277
  xml_url = "https://central.sonatype.com/repository/maven-snapshots/#{namespace}/#{artifact_coordinate}/#{version}-SNAPSHOT/maven-metadata.xml"
269
-
270
- response = Net::HTTP.get_response(URI(xml_url))
271
- if response.is_a?(Net::HTTPSuccess)
272
- xml = REXML::Document.new(response.body)
278
+ hermes_log("Checking #{xml_url} ...")
279
+ # response = Net::HTTP.get_response(URI(xml_url))
280
+ # if response.is_a?(Net::HTTPSuccess)
281
+ # xml = REXML::Document.new(response.body)
282
+ xml_text = read_nightly_tarball_xml(xml_url)
283
+ xml = REXML::Document.new(xml_text)
273
284
  timestamp = xml.elements['metadata/versioning/snapshot/timestamp'].text
274
285
  build_number = xml.elements['metadata/versioning/snapshot/buildNumber'].text
275
286
  full_version = "#{version}-#{timestamp}-#{build_number}"
276
287
  final_url = "https://central.sonatype.com/repository/maven-snapshots/#{namespace}/#{artifact_coordinate}/#{version}-SNAPSHOT/#{artifact_coordinate}-#{full_version}-#{artifact_name}"
277
288
 
278
289
  return final_url
279
- else
280
- return ""
281
- end
290
+ # else
291
+ # return ""
292
+ # end
282
293
  end
283
294
 
284
295
  def resolve_url_redirects(url)
@@ -1,2 +1,2 @@
1
1
  HERMES_VERSION_NAME=0.14.0
2
- HERMES_V1_VERSION_NAME=250829098.0.2
2
+ HERMES_V1_VERSION_NAME=250829098.0.3
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<6bc2fbc946e21d0b51dd9bc71ac041e7>>
7
+ * @generated SignedSource<<474b28e49cdb8a46a361a32df3c92eed>>
8
8
  * @flow strict
9
9
  * @noformat
10
10
  */
@@ -80,6 +80,7 @@ export type ReactNativeFeatureFlags = $ReadOnly<{
80
80
  enableImmediateUpdateModeForContentOffsetChanges: Getter<boolean>,
81
81
  enableImperativeFocus: Getter<boolean>,
82
82
  enableInteropViewManagerClassLookUpOptimizationIOS: Getter<boolean>,
83
+ enableIntersectionObserverByDefault: Getter<boolean>,
83
84
  enableKeyEvents: Getter<boolean>,
84
85
  enableLayoutAnimationsOnAndroid: Getter<boolean>,
85
86
  enableLayoutAnimationsOnIOS: Getter<boolean>,
@@ -104,6 +105,7 @@ export type ReactNativeFeatureFlags = $ReadOnly<{
104
105
  enableVirtualViewWindowFocusDetection: Getter<boolean>,
105
106
  enableWebPerformanceAPIsByDefault: Getter<boolean>,
106
107
  fixMappingOfEventPrioritiesBetweenFabricAndReact: Getter<boolean>,
108
+ fuseboxAssertSingleHostState: Getter<boolean>,
107
109
  fuseboxEnabledRelease: Getter<boolean>,
108
110
  fuseboxNetworkInspectionEnabled: Getter<boolean>,
109
111
  hideOffscreenVirtualViewsOnIOS: Getter<boolean>,
@@ -334,6 +336,10 @@ export const enableImperativeFocus: Getter<boolean> = createNativeFlagGetter('en
334
336
  * This is to fix the issue with interop view manager where component descriptor lookup is causing ViewManager to preload.
335
337
  */
336
338
  export const enableInteropViewManagerClassLookUpOptimizationIOS: Getter<boolean> = createNativeFlagGetter('enableInteropViewManagerClassLookUpOptimizationIOS', false);
339
+ /**
340
+ * Enables the IntersectionObserver Web API in React Native.
341
+ */
342
+ export const enableIntersectionObserverByDefault: Getter<boolean> = createNativeFlagGetter('enableIntersectionObserverByDefault', false);
337
343
  /**
338
344
  * Enables key up/down/press events to be sent to JS from components
339
345
  */
@@ -361,7 +367,7 @@ export const enableNativeCSSParsing: Getter<boolean> = createNativeFlagGetter('e
361
367
  /**
362
368
  * Enable network event reporting hooks in each native platform through `NetworkReporter`. This flag should be combined with `enableResourceTimingAPI` and `fuseboxNetworkInspectionEnabled` to enable end-to-end reporting behaviour via the Web Performance API and CDP debugging respectively.
363
369
  */
364
- export const enableNetworkEventReporting: Getter<boolean> = createNativeFlagGetter('enableNetworkEventReporting', false);
370
+ export const enableNetworkEventReporting: Getter<boolean> = createNativeFlagGetter('enableNetworkEventReporting', true);
365
371
  /**
366
372
  * Enables caching text layout artifacts for later reuse
367
373
  */
@@ -373,7 +379,7 @@ export const enablePropsUpdateReconciliationAndroid: Getter<boolean> = createNat
373
379
  /**
374
380
  * Enables the reporting of network resource timings through `PerformanceObserver`.
375
381
  */
376
- export const enableResourceTimingAPI: Getter<boolean> = createNativeFlagGetter('enableResourceTimingAPI', false);
382
+ export const enableResourceTimingAPI: Getter<boolean> = createNativeFlagGetter('enableResourceTimingAPI', true);
377
383
  /**
378
384
  * When enabled, it will use SwiftUI for filter effects like blur on iOS.
379
385
  */
@@ -430,6 +436,10 @@ export const enableWebPerformanceAPIsByDefault: Getter<boolean> = createNativeFl
430
436
  * Uses the default event priority instead of the discreet event priority by default when dispatching events from Fabric to React.
431
437
  */
432
438
  export const fixMappingOfEventPrioritiesBetweenFabricAndReact: Getter<boolean> = createNativeFlagGetter('fixMappingOfEventPrioritiesBetweenFabricAndReact', false);
439
+ /**
440
+ * Enable system assertion validating that Fusebox is configured with a single host. When set, the CDP backend will dynamically disable features (Perf and Network) in the event that multiple hosts are registered (undefined behaviour), and broadcast this over `ReactNativeApplication.systemStateChanged`.
441
+ */
442
+ export const fuseboxAssertSingleHostState: Getter<boolean> = createNativeFlagGetter('fuseboxAssertSingleHostState', true);
433
443
  /**
434
444
  * Flag determining if the React Native DevTools (Fusebox) CDP backend should be enabled in release builds. This flag is global and should not be changed across React Host lifetimes.
435
445
  */
@@ -437,7 +447,7 @@ export const fuseboxEnabledRelease: Getter<boolean> = createNativeFlagGetter('fu
437
447
  /**
438
448
  * Enable network inspection support in the React Native DevTools CDP backend. Requires `enableBridgelessArchitecture`. This flag is global and should not be changed across React Host lifetimes.
439
449
  */
440
- export const fuseboxNetworkInspectionEnabled: Getter<boolean> = createNativeFlagGetter('fuseboxNetworkInspectionEnabled', false);
450
+ export const fuseboxNetworkInspectionEnabled: Getter<boolean> = createNativeFlagGetter('fuseboxNetworkInspectionEnabled', true);
441
451
  /**
442
452
  * Hides offscreen VirtualViews on iOS by setting hidden = YES to avoid extra cost of views
443
453
  */
@@ -4,7 +4,7 @@
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
6
6
  *
7
- * @generated SignedSource<<0b1f3b307c28d6798d4c15029ad5bc58>>
7
+ * @generated SignedSource<<fecd2198c65b74c22fa1a6ce96343228>>
8
8
  * @flow strict
9
9
  * @noformat
10
10
  */
@@ -55,6 +55,7 @@ export interface Spec extends TurboModule {
55
55
  +enableImmediateUpdateModeForContentOffsetChanges?: () => boolean;
56
56
  +enableImperativeFocus?: () => boolean;
57
57
  +enableInteropViewManagerClassLookUpOptimizationIOS?: () => boolean;
58
+ +enableIntersectionObserverByDefault?: () => boolean;
58
59
  +enableKeyEvents?: () => boolean;
59
60
  +enableLayoutAnimationsOnAndroid?: () => boolean;
60
61
  +enableLayoutAnimationsOnIOS?: () => boolean;
@@ -79,6 +80,7 @@ export interface Spec extends TurboModule {
79
80
  +enableVirtualViewWindowFocusDetection?: () => boolean;
80
81
  +enableWebPerformanceAPIsByDefault?: () => boolean;
81
82
  +fixMappingOfEventPrioritiesBetweenFabricAndReact?: () => boolean;
83
+ +fuseboxAssertSingleHostState?: () => boolean;
82
84
  +fuseboxEnabledRelease?: () => boolean;
83
85
  +fuseboxNetworkInspectionEnabled?: () => boolean;
84
86
  +hideOffscreenVirtualViewsOnIOS?: () => boolean;
@@ -41,4 +41,10 @@ export default function setUpDefaltReactNativeEnvironment(
41
41
  }
42
42
 
43
43
  require('../../../Libraries/ReactNative/AppRegistry');
44
+
45
+ if (
46
+ require('../../../src/private/featureflags/ReactNativeFeatureFlags').enableIntersectionObserverByDefault()
47
+ ) {
48
+ require('./setUpIntersectionObserver').default();
49
+ }
44
50
  }