html code:
<audio id="notification" src="../assets/audio/notification.mp3" autoplay="true"
muted="muted"></audio>
ts code:
let audioPlayer = <HTMLAudioElement> document.getElementById('notification');
audioPlayer.muted = false;
audioPlayer.play();
I am getting error play() failed because the user didn't interact with the document first.