Skip to content

Instantly share code, notes, and snippets.

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 mazharulbelal/96d31b45255f55b5cf3d6e324da2aac0 to your computer and use it in GitHub Desktop.
Save mazharulbelal/96d31b45255f55b5cf3d6e324da2aac0 to your computer and use it in GitHub Desktop.
Open UIKit ViewController( Present) on SwiftUI Button clicked
Button("Next Page") {
let storyboard = UIStoryboard(name: "Profile", bundle: nil)
let rootViewController = storyboard.instantiateViewController(withIdentifier: "ProfileVC")
if let window = UIApplication.shared.windows.first {
window.rootViewController!.present(rootViewController, animated: true)
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment