Solved: Flutter how to programmatically exit the app
How can I programmatically close a Flutter application. I've tried popping the only screen but that results in a black screen.
SystemNavigator.pop(): Does NOT WORK
exit(0): Works but Apple may SUSPEND YOUR APP because it's against Apple Human Interface guidelines to exit the app programmatically.
SystemNavigator.pop(): Works and is the RECOMMENDED way of exiting the app.
exit(0): Also works but it's NOT RECOMMENDED as it terminates the Dart VM process immediately and user may think that the app just got crashed.