@@ -102,14 +102,18 @@ def resources_pod(project_root, platforms, resources)
102102 Pathname . new ( app_dir ) . relative_path_from ( project_root ) . to_s
103103end
104104
105- def use_react_native! ( project_root , react_native , version , options )
106- require_relative ( react_native_pods ( version ) )
105+ def use_react_native! ( project_root , project , options )
106+ require_relative ( react_native_pods ( project [ :react_native_version ] ) )
107+
108+ react_native_path = Pathname . new ( project [ :react_native_path ] )
107109
108110 include_react_native! ( **options ,
109111 app_path : find_file ( 'package.json' , project_root ) . parent . to_s ,
110- path : Pathname . new ( react_native ) . relative_path_from ( project_root ) . to_s ,
112+ path : react_native_path . relative_path_from ( project_root ) . to_s ,
111113 rta_project_root : project_root ,
112- version : version )
114+ use_new_arch : project [ :use_new_arch ] ,
115+ use_bridgeless : project [ :use_bridgeless ] ,
116+ version : project [ :react_native_version ] )
113117end
114118
115119def make_project! ( project_root , target_platform , options )
@@ -165,6 +169,7 @@ def make_project!(project_root, target_platform, options)
165169 :react_native_host_path => project [ 'reactNativeHostPath' ] ,
166170 :community_autolinking_script_path => project [ 'communityAutolinkingScriptPath' ] ,
167171 :use_new_arch => project [ 'useNewArch' ] ,
172+ :use_bridgeless => project [ 'useBridgeless' ] ,
168173 :code_sign_identity => build_settings [ CODE_SIGN_IDENTITY ] || '' ,
169174 :development_team => build_settings [ DEVELOPMENT_TEAM ] || '' ,
170175 :resources => project [ 'resources' ] ,
@@ -179,11 +184,9 @@ def use_test_app_internal!(target_platform, options)
179184 xcodeproj = 'ReactTestApp.xcodeproj'
180185 project_root = Pod ::Config . instance . installation_root
181186 project_target = make_project! ( project_root , target_platform , options )
182- xcodeproj_dst , platforms , react_native_path , react_native_version = project_target . values_at (
183- :xcodeproj_path , :platforms , :react_native_path , :react_native_version
184- )
187+ xcodeproj_dst , platforms = project_target . values_at ( :xcodeproj_path , :platforms )
185188
186- if project_target [ :use_new_arch ] || react_native_version >= v ( 0 , 73 , 0 )
189+ if project_target [ :use_new_arch ] || project_target [ : react_native_version] >= v ( 0 , 73 , 0 )
187190 install! 'cocoapods' , :deterministic_uuids => false
188191 end
189192
@@ -205,10 +208,7 @@ def use_test_app_internal!(target_platform, options)
205208 react_native_post_install = nil
206209
207210 target 'ReactTestApp' do
208- react_native_post_install = use_react_native! ( project_root ,
209- react_native_path ,
210- react_native_version ,
211- options )
211+ react_native_post_install = use_react_native! ( project_root , project_target , options )
212212
213213 pod 'ReactNativeHost' , :path => project_target [ :react_native_host_path ]
214214
0 commit comments