From ebc1bdc9e81fe10221083ba9d4d27995ca93949c Mon Sep 17 00:00:00 2001 From: Tommy Nguyen <4123478+tido64@users.noreply.github.com> Date: Mon, 21 Feb 2022 16:22:09 +0100 Subject: [PATCH] fix(ios): update Fabric in Podfile instructions (#2973) * fix(ios): update Fabric in Podfile instructions * move fabric_enabled comment closer to the property --- docs/new-architecture-app-renderer-ios.md | 38 ++++++++--------------- 1 file changed, 13 insertions(+), 25 deletions(-) diff --git a/docs/new-architecture-app-renderer-ios.md b/docs/new-architecture-app-renderer-ios.md index 2baf4d9070b..c4ccaa7907f 100644 --- a/docs/new-architecture-app-renderer-ios.md +++ b/docs/new-architecture-app-renderer-ios.md @@ -28,32 +28,20 @@ target 'Some App' do end def pods() -# Get config -config = use_native_modules! - -# Use env variables to turn it on/off. -fabric_enabled = ENV['USE_FABRIC'] -use_codegen_discovery= ENV['USE_CODEGEN_DISCOVERY'] - -# Enabled codegen discovery. This will run the codegen at preinstall time. -# Files are generated at {pod installation root}/build/generated/ios/ -if use_codegen_discovery - Pod::UI.puts "[Codegen] Building target with codegen library discovery enabled." - pre_install do |installer| - use_react_native_codegen_discovery!({ - react_native_path: config[:reactNativePath], - # Modify here if your app root path isn't the same as this one. - app_path: "#{Dir.pwd}/..", - fabric_enabled: fabric_enabled, - }) - end + # Get config + config = use_native_modules! + + # Use env variables to turn it on/off. + fabric_enabled = ENV['USE_FABRIC'] + + use_react_native!( + ... + # Modify here if your app root path isn't the same as this one. + :app_path => "#{Dir.pwd}/..", + # Pass the flag to enable fabric to use_react_native!. + :fabric_enabled => fabric_enabled + ) end - -# Pass the flag to enable fabric to use_react_native!. -use_react_native!( - ... - :fabric_enabled => fabric_enabled -) ``` ## 2. Update your root view