macosPluginSwiftStub function

String macosPluginSwiftStub(
  1. String className
)

macOS *Plugin.swift stub — created when the file is missing.

Implementation

String macosPluginSwiftStub(String className) =>
    '''import FlutterMacOS
import Foundation

public class ${className}Plugin: NSObject, FlutterPlugin {
  public static func register(with registrar: FlutterPluginRegistrar) {
    // Nitro registration will be injected here by nitrogen link.
  }
}
''';