Podfile 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  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 'CompdfkitPdfExample' do
  15. config = use_native_modules!
  16. pod "ComPDFKit", podspec:'https://www.compdf.com/download/ios/cocoapods/xcframeworks/compdfkit/2.1.2.podspec'
  17. pod "ComPDFKit_Tools", podspec:'https://www.compdf.com/download/ios/cocoapods/xcframeworks/compdfkit_tools/2.1.2.podspec'
  18. use_react_native!(
  19. :path => config[:reactNativePath],
  20. # An absolute path to your application root.
  21. :app_path => "#{Pod::Config.instance.installation_root}/.."
  22. )
  23. target 'CompdfkitPdfExampleTests' do
  24. inherit! :complete
  25. # Pods for testing
  26. end
  27. post_install do |installer|
  28. # https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/react_native_pods.rb#L197-L202
  29. react_native_post_install(
  30. installer,
  31. config[:reactNativePath],
  32. :mac_catalyst_enabled => false,
  33. # :ccache_enabled => true
  34. )
  35. end
  36. end