Skip to content

Commit 25c5539

Browse files
j-piaseckimeta-codesync[bot]
authored andcommitted
Cover react/renderer/attributedstring with Stable API guards (#58305)
Summary: Pull Request resolved: #58305 Classifies `react/renderer/attributedstring:attributedstring` as a "for frameworks" target under the three-tier C++ stable API visibility model. Consumers that opt into `RN_STRICT_API` now get a warning if they include its headers directly, which they can acknowledge with `RN_ALLOW_FRAMEWORKS`; without that flag the guards are inert, so no existing build changes behaviour. `React-Fabric` already depended on `React-cxxstableapi` from an earlier migration in the same pod, so the module's subspec needs no change. Changelog: [Internal] Reviewed By: rubennorte Differential Revision: D118619367 fbshipit-source-id: 711404c0388c49112c23a63a9ac96b080fc3fda8
1 parent 8cfde6d commit 25c5539

8 files changed

Lines changed: 15 additions & 0 deletions

File tree

‎packages/react-native/ReactCommon/react/renderer/attributedstring/AttributedString.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <react/renderer/attributedstring/TextAttributes.h>
1113
#include <react/renderer/core/Sealable.h>
1214
#include <react/renderer/debug/DebugStringConvertible.h>

‎packages/react-native/ReactCommon/react/renderer/attributedstring/AttributedStringBox.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <memory>
1113

1214
#include <react/renderer/attributedstring/AttributedString.h>

‎packages/react-native/ReactCommon/react/renderer/attributedstring/CMakeLists.txt‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ target_link_libraries(react_renderer_attributedstring
1717
folly_runtime
1818
glog
1919
glog_init
20+
react_cxxstableapi
2021
react_debug
2122
rrc_view
2223
react_renderer_core

‎packages/react-native/ReactCommon/react/renderer/attributedstring/ParagraphAttributes.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <limits>
1113

1214
#include <react/renderer/attributedstring/primitives.h>

‎packages/react-native/ReactCommon/react/renderer/attributedstring/PlaceholderAttributedString.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <react/renderer/attributedstring/AttributedString.h>
1113

1214
namespace facebook::react {

‎packages/react-native/ReactCommon/react/renderer/attributedstring/TextAttributes.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <functional>
1113
#include <limits>
1214
#include <optional>

‎packages/react-native/ReactCommon/react/renderer/attributedstring/conversions.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <react/debug/react_native_expect.h>
1113
#include <react/featureflags/ReactNativeFeatureFlags.h>
1214
#include <react/renderer/attributedstring/AttributedString.h>

‎packages/react-native/ReactCommon/react/renderer/attributedstring/primitives.h‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@
77

88
#pragma once
99

10+
#include <react/cxxstableapi/FrameworksGuard.h>
11+
1012
#include <functional>
1113
#include <limits>
1214

0 commit comments

Comments
 (0)