Taio
Taio

Reputation: 3734

How to make a task run in the background in Flutter

I have a music app that streams audio online. The only problem is it gets killed every time I exit the app which is not good for the user. They need it to keep running in the background even after exiting. How can I achieve this?

Upvotes: 7

Views: 10303

Answers (1)

Raouf Rahiche
Raouf Rahiche

Reputation: 31356

Can I run Dart code in the background of an Flutter app?

Yes, you can run Dart code in a background process on both iOS and Android. For more information, see the Medium article Executing Dart in the Background with Flutter Plugins and Geofencing.

Upvotes: 4

Related Questions