I am building an app that monitors people's safety. The Web app plays a sound to alert the user that somebody is in danger. I am having issues with the sound not playing if the page has not been interacted with in some time. It can be hours or days between these alerts.
Is there a way (chrome setting, flag, feature) that would ensure this sounds always plays regardless of how long the page has been sitting there?
This issue occurs in all modern browsers (Chrome, Edge, etc). I'm using an HTMLAudioElement
Thus far I've tried implementing a check to see if the user's sound settings are disabled and I show a message telling them so on the web page, but it doesn't help if the user doesn't look at the tab to see it.