美文网首页
flutter与iOS混编(一)集成

flutter与iOS混编(一)集成

作者: 喜剧收尾_XWX | 来源:发表于2021-03-14 22:29 被阅读0次

    1.创建flutter_module

    flutter create -t module flutter_module
    

    2.iOS工程和flutter_module放在同一目录下

    目录结构

    3.打开flutter_module运行flutter pub get

    4.配置原生cocoapod

    # Uncomment the next line to define a global platform for your project
    platform :ios, '9.0'
    flutter_application_path = "../flutter_module/"
    load File.join(flutter_application_path, '.ios', 'Flutter', 'podhelper.rb')
    
    inhibit_all_warnings!
    
    
    target 'ObjcGo' do
      # Comment the next line if you don't want to use dynamic frameworks
      use_frameworks!
    
      # Pods for ObjcGo
    
      #flutter
        install_all_flutter_pods(flutter_application_path)
    
      target 'ObjcGoTests' do
        inherit! :search_paths
        # Pods for testing
      end
    
      target 'ObjcGoUITests' do
        # Pods for testing
      end
    
    end
    
    

    5.设置Bitcode

    Bitcode

    相关文章

      网友评论

          本文标题:flutter与iOS混编(一)集成

          本文链接:https://www.haomeiwen.com/subject/ueoccltx.html