Skip to content

Instantly share code, notes, and snippets.

@shirakaba
Created December 10, 2018 23:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shirakaba/c2731582f4d92140ae155eb8bfe75856 to your computer and use it in GitHub Desktop.
Save shirakaba/c2731582f4d92140ae155eb8bfe75856 to your computer and use it in GitHub Desktop.
Entry file for a React Native Swift app
#if canImport(UIKit)
import UIKit
UIApplicationMain(
CommandLine.argc,
CommandLine.unsafeArgv,
NSStringFromClass(UIApplication.self),
NSStringFromClass(AppDelegate.self)
)
#elseif canImport(Cocoa)
import Cocoa
NSApplicationMain(
CommandLine.argc,
CommandLine.unsafeArgv,
NSStringFromClass(NSApplication.self),
NSStringFromClass(AppDelegate.self)
)
#endif
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment