In a server-side VM app, with a few Futures which may or may not return. How to unconditionally exit the app?
To exit the VM:
import 'dart:io';
main() {
exit(0); // or non-zero for some error code
}
Which is documented here. Thanks for asking!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With