I wanted to create a music player using react-native-sounds but and it was playing music flawless but the issue wast it was not stoping when i press the button, btw the button of play & pause is same.I also want it to pause when another track is playing or navigating out of that screen.

I have tried giving all type of condition's in the button to play and pause on state change, twist is that when I use seprate button it pause and play fine but not in same button.

0

There are 0 best solutions below