Issue
After reading android user agent I set in WebView:
webView.settings.apply {
userAgentString = "some string"
javaScriptEnabled = true
javaScriptCanOpenWindowsAutomatically = true
domStorageEnabled = true
}
And loaded the URL "https://www.whoishostingthis.com/tools/user-agent/". In emulators of API 21 and 29 it worked right. But in API 30 it showed:
How to change user-agent in API 30?
Solution
According to https://www.infoq.com/news/2020/03/chrome-phasing-user-agent/, Chrome will replace User-Agent
with a new API called Client Hints
.
Answered By - CoolMind
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.