This repository has been archived by the owner on Dec 14, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 50
Service killed if main activity cleaned up on Android #6
Comments
Here's a logcat dump of what happens. The music stops instantly.
|
Hi @jasongrishkoff |
Hey @anderslemke, we've been working on a new project over here: https://github.com/Guichaguri/react-native-track-player/ (in the dev branch). It's much more functional! |
Hi @jasongrishkoff |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hey so, if my main React Native application is cleared up by Android for memory, the service also stops. This kinda sucks because it means if they're listening to a song, it ends mid-way. I've tried as much as I can to lower the memory footprint of my app, but if I'm doing heavy browsing on multiple apps in the foreground, Android cleans it up.
Any idea how to tweak the code to keep the RNAudioStreamer service alive and avoid Android from killing it when it clears up memory from the main activity? I've been looking into:
Both might be helpful, but not sure where I'd throw those into the code...
The text was updated successfully, but these errors were encountered: