mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Cover react/nativemodule/microtasks:microtasks with Stable API guards (#58027)
Summary: Pull Request resolved: https://github.com/react/react-native/pull/58027 Classifies `react/nativemodule/microtasks:microtasks` as a private target under the C++ stable API three-tier visibility model. Adds `#include <react/cxxstableapi/PrivateGuard.h>` to the module's only header, `NativeMicrotasks.h`, and declares the guard dependency in BUCK, CMake, and the podspec. Consumers that opt into `RN_STRICT_API` now get a hard error if they include it directly, with no escape hatch; without that flag the guard is inert, so no existing build changes behaviour. Changelog: [Internal] Reviewed By: cortinico Differential Revision: D116612641 fbshipit-source-id: e72af6de67f4e632547528bfbfe9cbd3a2ecd52a
This commit is contained in:
1 parent
99944312fc
commit
16f8889908
3 files changed
+4
No files matched your search
@@ -16,6 +16,7 @@ target_include_directories(react_nativemodule_microtasks PUBLIC ${REACT_COMMON_D
|
||||
target_link_libraries(react_nativemodule_microtasks
|
||||
react_codegen_rncore
|
||||
react_cxxreact
|
||||
react_cxxstableapi
|
||||
)
|
||||
target_compile_reactnative_options(react_nativemodule_microtasks PRIVATE)
|
||||
target_compile_options(react_nativemodule_microtasks PRIVATE -Wpedantic)
|
||||
@@ -7,6 +7,8 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#include <react/cxxstableapi/PrivateGuard.h>
|
||||
|
||||
#if __has_include("FBReactNativeSpecJSI.h") // CocoaPod headers on Apple
|
||||
#include "FBReactNativeSpecJSI.h"
|
||||
#else
|
||||
|
||||
+1
@@ -48,6 +48,7 @@ Pod::Spec.new do |s|
|
||||
add_rncore_dependency(s)
|
||||
|
||||
s.dependency "ReactCommon/turbomodule/core"
|
||||
s.dependency "React-cxxstableapi"
|
||||
add_dependency(s, "React-RCTFBReactNativeSpec")
|
||||
|
||||
mark_as_react_native_build(s)
|
||||
|
||||
Reference in new issue
Block a user