Uncaught (in promise) DOMException: play() failed because the user didn't interact with the document

最近在開發一個網站時,有個須要是 若是有新預警信息要在網頁中播放提示音。頁面打開會請求是否有新信息,有則播放提示音。在Chrome的最新瀏覽器中,播放會報錯,控制檯顯示Uncaught (in promise) DOMException: play() failed because the user didn't interact with the document first.搜索發現Chrom
相關文章
相關標籤/搜索