Detecting mute switch on a web app

I work on a web app that uses WebAudio. If the device has the mute switch on, the WebAudio won't play. From Apple's documentation, when a device is muted, it won't play:


  • Alerts
  • Notifications
  • Sound effects
  • Game audio

However it will play:


  • Music
  • Podcasts
  • Movies
  • Videos
  • TV shows


I was wondering if there is a way to detect if the device has the mute switch ON. If not, is there a way to still play WebAudio when muted? Maybe playing it as "Music"?

There's a workaround here - https://github.com/feross/unmute-ios-audio

Detecting mute switch on a web app
 
 
Q