--> ForSharing.Info, [Keep Better In The Life] | [ForSharing
picture

Blog

[React Native] How to use Podfile usefull



http://facebook.github.io/react-native/docs/integration-with-existing-apps

1 file Podfile cơ bản để có thể run được 1 project React Native tích hợp Cocoapods. 1 thư viện open source khổng lồ để sử dụng libs và tích hợp dễ dàng hơn.

# The target name is most likely the name of your project.
target 'Tên của project' do

  # Your 'node_modules' directory is probably in the root of your project,
  # but if not, adjust the `:path` accordingly
  pod 'React', :path => '../node_modules/react-native', :subspecs => [
    'Core',
    'CxxBridge', # Include this for RN >= 0.47
    'DevSupport', # Include this to enable In-App Devmenu if RN >= 0.43
    'RCTText',
    'RCTNetwork',
    'RCTWebSocket', # Needed for debugging
    'RCTAnimation', # Needed for FlatList and animations running on native UI thread
    # Add any other subspecs you want to use in your project
  ]
  # Explicitly include Yoga if you are using RN >= 0.42.0
  pod 'yoga', :path => '../node_modules/react-native/ReactCommon/yoga'

  # Third party deps podspec link
  pod 'DoubleConversion', :podspec => '../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
  pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec'
  pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'

end

Trả lời

Email của bạn sẽ không được hiển thị công khai. Các trường bắt buộc được đánh dấu *


« »

WP2Social Auto Publish Powered By : XYZScripts.com