Cover react/nativemodule/webperformance with Stable API guards (#58123)

Summary:
Pull Request resolved: https://github.com/react/react-native/pull/58123

Classifies `react/nativemodule/webperformance:webperformance` as a private target under the C++ stable API three-tier visibility model. Adds `#include <react/cxxstableapi/PrivateGuard.h>` to the module's single exported header (`NativePerformance.h`), and wires the guard dependency into BUCK, CMake, and the podspec.

The guards are inert unless a consumer defines `RN_STRICT_API`, so there is no behavior change.

Changelog: [Internal]

Reviewed By: cortinico

Differential Revision: D117322371

fbshipit-source-id: e99c9d1f867a843da60f5166621cc7794dfbbe1e
This commit is contained in:
Jakub Piasecki authored and meta-codesync[bot] committed 2026-08-26 03:27:51 -07:00
1 parent 9682967a09
commit 60b08c60f1
3 files changed
+4

No files matched your search

@@ -16,6 +16,7 @@ target_link_libraries(react_nativemodule_webperformance
react_performance_timeline
react_codegen_rncore
react_cxxreact
react_cxxstableapi
)
target_compile_reactnative_options(react_nativemodule_webperformance PRIVATE)
target_compile_options(react_nativemodule_webperformance PRIVATE -Wpedantic -Wno-deprecated-declarations)
@@ -7,6 +7,8 @@
#pragma once
#include <react/cxxstableapi/PrivateGuard.h>
#if __has_include("rncoreJSI.h") // Cmake headers on Android
#include "rncoreJSI.h"
#elif __has_include("FBReactNativeSpecJSI.h") // CocoaPod headers on Apple
@@ -53,6 +53,7 @@ Pod::Spec.new do |s|
s.dependency "ReactCommon/turbomodule/core"
s.dependency "React-bridging"
s.dependency "React-cxxstableapi"
add_dependency(s, "React-RCTFBReactNativeSpec")
add_dependency(s, "React-performancetimeline")