Is there a way to do a task when an app is placed in the background?

Or this:

save it with TinyDB in the ActivityLifecycle.Stop event and get TinyDB in the ActivityLifecycle.Resume event.

1 Like