Skip to content

Commit

Permalink
isolate use of folly to interpolateViewProps on Android (#48556)
Browse files Browse the repository at this point in the history
Summary:

changelog: [react-native]

the only place in view module that uses folly is `ViewPropsInterpolation.h` and that is only on Android. 
This diff makes that dependency explicit and make it android only.

Differential Revision: D67942951
  • Loading branch information
sammy-SC authored and facebook-github-bot committed Jan 10, 2025
1 parent a40a885 commit e6cf603
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@
#include <react/renderer/components/view/ViewProps.h>
#include <react/renderer/graphics/Transform.h>

#ifdef ANDROID
#include <folly/dynamic.h>
#endif

namespace facebook::react {

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

#pragma once

#include <folly/Conv.h>
#include <folly/dynamic.h>
#include <glog/logging.h>
#include <react/debug/react_native_expect.h>
#include <react/renderer/components/view/primitives.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

#include "Props.h"

#include <folly/dynamic.h>
#include <react/renderer/core/propsConversions.h>

#include <react/featureflags/ReactNativeFeatureFlags.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@

#pragma once

#include <folly/dynamic.h>

#include <react/renderer/core/PropsMacros.h>
#include <react/renderer/core/PropsParserContext.h>
#include <react/renderer/core/RawProps.h>
Expand All @@ -17,6 +15,7 @@
#include <react/renderer/debug/DebugStringConvertible.h>

#ifdef ANDROID
#include <folly/dynamic.h>
#include <react/renderer/mapbuffer/MapBufferBuilder.h>
#endif

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

#pragma once

#include <cstdint>
#include <limits>

namespace facebook::react {
Expand Down

0 comments on commit e6cf603

Please sign in to comment.