How to prevent double prompt for geolocation in WKWebView?

I've an app that load my website on WKWebView.

My website make use in JavaScript geolocation API to find user location.

when I start the app, I see two geolcation permission prompts in a row: one for the app and one for the webview.


1st prompt: Allow "AppName" to access your location while you use the app?

2nd prompt: "My website" Would Like To Use Your Current Location


How can I prevent the 2nd prompt?

Replies

Did you find the solution to prevent the 2nd prompt?