Embed video in WKWebview stop music in background

Hello,


I have an issue with WKWebview and the inter-app audio.

Let me explain the situation :

  • I have an application like spotify which play, in background, music
  • I have an app which can open a webview (a WKWebview) and play video like youtube or just a sound.
  • When the video or sound is playing in the webview the background music is stopped as well


I have already configure my app to be able to mix sounds, in my app, I have also a player and when I start my player the background music is not stopped.

Very weird comportement because if I use UIWebview, the background music is not stopped when the embed video is starting in the webview.


Why there is a difference between UIWebview and WKWebview ? Have you ever had this issue ? Is there a fix for this issue ?


Thanks.

Replies

When the video is playing in the WKWebView at iOS10 the background music does not stop.

I think it's a bug...😠

We have the excat same Problem! Nothing new even with iOS 11.1.1