require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'

source 'https://github.com/react-native-tvos/react-native-tvos-podspecs.git'
source 'https://cdn.cocoapods.org/'

target 'tv' do

  platform :ios, '10.0'

  config = use_native_modules!

  use_react_native!(
    :path => config[:reactNativePath],
    # to enable hermes on iOS, change `false` to `true` and then install pods
    :hermes_enabled => false
  )

  target 'tvTests' do
    inherit! :complete
    # Pods for testing
  end

end

target 'tv-tvOS' do

  platform :tvos, '12.0'

  config = use_native_modules!

  # Hermes not yet available on tvOS
  use_react_native!(:path => config["reactNativePath"])

  target 'tv-tvOSTests' do
    inherit! :complete
    # Pods for testing
  end

end

post_install do |installer|
  flipper_post_install(installer)
end
