Podfile 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # Resolve react_native_pods.rb with node to allow for hoisting
  2. require Pod::Executable.execute_command('node', ['-p',
  3. 'require.resolve(
  4. "react-native/scripts/react_native_pods.rb",
  5. {paths: [process.argv[1]]},
  6. )', __dir__]).strip
  7. platform :ios, min_ios_version_supported
  8. prepare_react_native_project!
  9. linkage = ENV['USE_FRAMEWORKS']
  10. if linkage != nil
  11. Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green
  12. use_frameworks! :linkage => linkage.to_sym
  13. end
  14. target 'nxsample' do
  15. config = use_native_modules!
  16. use_react_native!(
  17. :path => config[:reactNativePath],
  18. # An absolute path to your application root.
  19. :app_path => "#{Pod::Config.instance.installation_root}/.."
  20. )
  21. target 'nxsampleTests' do
  22. inherit! :complete
  23. # Pods for testing
  24. end
  25. post_install do |installer|
  26. # https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/react_native_pods.rb#L197-L202
  27. react_native_post_install(
  28. installer,
  29. config[:reactNativePath],
  30. :mac_catalyst_enabled => false,
  31. # :ccache_enabled => true
  32. )
  33. end
  34. end