Using Cocoapods in an app extension using a framework

后端 未结 3 1368
滥情空心
滥情空心 2020-12-09 03:14

I have an app (let\'s call it MyApp) written in Swift with the following targets :

  • MyApp : the main target
  • MyAppKit : a targ
3条回答
  •  天涯浪人
    2020-12-09 04:02

    This is a swift-3.0 project's profile example.

    platform :ios, '8.0'
    
    def import_public_pods
    
      pod 'SwiftyJSON'
    
    end
    
    
    target 'Demo' do
      use_frameworks!
    
      # Pods for Demo
      import_public_pods 
      pod 'Fabric'
      pod 'Crashlytics'
    
      target 'DemoTests' do
        inherit! :search_paths
        # Pods for testing
      end
    
      target 'DemoUITests' do
        inherit! :search_paths
        # Pods for testing
      end
    
    end
    
    
    target 'DemoKit' do
      use_frameworks!
    
      # Pods for DemoKit
      import_public_pods
      pod 'RealmSwift'
    
      target 'DemoKitTests' do
        inherit! :search_paths
        # Pods for testing
      end
    
    end
    

提交回复
热议问题