-
-
Notifications
You must be signed in to change notification settings - Fork 491
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: refactor snapshots when going back on Fabric #2134
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work! Overall, this code looks good to me. Just left a few remarks there 🎉
@@ -4,7 +4,7 @@ package = JSON.parse(File.read(File.join(__dir__, "package.json"))) | |||
|
|||
new_arch_enabled = ENV['RCT_NEW_ARCH_ENABLED'] == '1' | |||
platform = new_arch_enabled ? "11.0" : "9.0" | |||
source_files = new_arch_enabled ? 'ios/**/*.{h,m,mm,cpp}' : ["ios/**/*.{h,m,mm}", "cpp/**/*.{cpp,h}"] | |||
source_files = new_arch_enabled ? 'ios/**/*.{h,m,mm,cpp}' : ["ios/**/*.{h,m,mm}", "cpp/RNScreensTurboModule.cpp", "cpp/RNScreensTurboModule.h"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why we're not scoping all .cpp and .h files right now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because the new files added to the folder should not be compiled on old arch.
android/CMakeLists.txt
Outdated
target_include_directories( | ||
rnscreens | ||
PRIVATE | ||
"${REACT_NATIVE_DIR}/ReactAndroid/src/main/jni/react/turbomodule" | ||
"${REACT_NATIVE_DIR}/ReactCommon" | ||
"${REACT_NATIVE_DIR}/ReactCommon/callinvoker" | ||
"${REACT_NATIVE_DIR}/ReactCommon/react/renderer/graphics/platform/cxx" | ||
"${REACT_NATIVE_DIR}/ReactCommon/runtimeexecutor" | ||
"${REACT_NATIVE_DIR}/ReactCommon/yoga" | ||
) | ||
|
||
find_package(fbjni REQUIRED CONFIG) | ||
|
||
target_link_libraries( | ||
rnscreens | ||
ReactAndroid::jsi | ||
ReactAndroid::folly_runtime | ||
ReactAndroid::react_nativemodule_core | ||
ReactAndroid::react_render_uimanager | ||
ReactAndroid::react_render_scheduler | ||
ReactAndroid::react_utils | ||
ReactAndroid::reactnativejni | ||
ReactAndroid::fabricjni | ||
ReactAndroid::react_debug | ||
ReactAndroid::react_render_core | ||
ReactAndroid::react_render_mounting | ||
ReactAndroid::runtimeexecutor | ||
ReactAndroid::react_render_graphics | ||
ReactAndroid::rrc_view | ||
ReactAndroid::yoga | ||
ReactAndroid::rrc_text | ||
ReactAndroid::rrc_textinput | ||
ReactAndroid::react_render_textlayoutmanager | ||
ReactAndroid::glog | ||
ReactAndroid::react_render_componentregistry | ||
fbjni::fbjni | ||
android | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why will we link all of these modules from now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
They are all needed to compile the new files. I'll go through them once again to see if we can remove any of those.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok I cleared it a bit. It won't get better than this :D
Hi @WoLewicki! While I was testing all examples from FabricTestExample, I've stumbled onto one app crash while being on the branch from this PR. When I'm trying to run Exception from Logcat
|
Description
PR refactoring snapshots when going back on Fabric on both platforms.