Capacitor kill my music player

i have 1 major issue in my capacitor app when stream on background /lockscreen mode the app destory the javacript from working so the music player only play 1 or 2 song and never play any again until i turn phone screen on and open the app that when the music continue please any sultion to stop capacitor app from doing this

what kind of plugin can someone build to tackle the capcitor deep sleep so that when lock screen or background mode capcitor we not kill the app or kill javascript and page in the app no matter how long it take like a native package that one can add to stop the deep sleep for ever in the app or wrapp the whol capcitor project any something that we totaltaly prevent deep sleep i need deep research i need to know they have to be solution that i can build

You need to use a native audio player. See Audio stops playing after some time on iOS (works fine on Android) - #2 by twestrick

Hey, I suggest you to use a native plugin like the Capacitor Audio Player. It has background support. The problem is not the capacitor app, is your implementation. For this kind of features you have to use native plugins.