Skip to content

Commit 68eaa2d

Browse files
antonisclaude
andcommitted
fix(core): Replace deprecated rncore.h with FBReactNativeSpec.h
rncore.h is deprecated in RN 0.84 and triggers -Werror. Replace with FBReactNativeSpec.h and FBReactNativeSpec_ModuleProvider. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent fb4a398 commit 68eaa2d

File tree

1 file changed

+3
-3
lines changed
  • samples/react-native/android/app/src/main/jni

1 file changed

+3
-3
lines changed

samples/react-native/android/app/src/main/jni/OnLoad.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
#include <autolinking.h>
3434
#include <fbjni/fbjni.h>
3535
#include <react/renderer/componentregistry/ComponentDescriptorProviderRegistry.h>
36-
#include <rncore.h>
36+
#include <FBReactNativeSpec.h>
3737

3838
#ifdef REACT_NATIVE_APP_CODEGEN_HEADER
3939
# include REACT_NATIVE_APP_CODEGEN_HEADER
@@ -91,7 +91,7 @@ javaModuleProvider(const std::string &name, const JavaTurboModule::InitParams &p
9191
// if (module != nullptr) {
9292
// return module;
9393
// }
94-
// return rncore_ModuleProvider(name, params);
94+
// return FBReactNativeSpec_ModuleProvider(name, params);
9595

9696
// We link app local modules if available
9797
#ifdef REACT_NATIVE_APP_MODULE_PROVIDER
@@ -102,7 +102,7 @@ javaModuleProvider(const std::string &name, const JavaTurboModule::InitParams &p
102102
#endif
103103

104104
// We first try to look up core modules
105-
if (auto module = rncore_ModuleProvider(name, params)) {
105+
if (auto module = FBReactNativeSpec_ModuleProvider(name, params)) {
106106
return module;
107107
}
108108

0 commit comments

Comments
 (0)