Swift

Objective-C

Start by opening the iOS host portion of your Flutter app in Xcode:

Start Xcode.

Select the menu item File > Open….

Navigate to the directory holding your Flutter app, and select the ios
folder inside it. Click OK.

Add support for Swift in the standard template setup that uses Objective-C:

Expand Runner > Runner in the Project navigator.

Open the file AppDelegate.swift located under Runner > Runner
in the Project navigator.

Override the application:didFinishLaunchingWithOptions: function and create
a FlutterMethodChannel tied to the channel name
samples.flutter.dev/battery:

@UIApplicationMain

@objc

class

AppDelegate

FlutterAppDelegate

override

func

application