How do I know if WKWebView is playing audio?

I was curious if there is a way to tell if the sound comes from a specific WKWebView, similar to how you can find the tab that plays sound in Chrome and Safari?

+6
source share
1 answer

In the WKWebView delegate, after the browser finishes loading, execute javascript with the addEventListener tags before audio and video with the play , pause , ended event. Then check the playback status for goals.

+2
source

All Articles