I want to fit large image into UIwebview with keeping image ratio same as image view.
How can i do
To load image in Swift 3.0 from application document directory in a UIWebView with his expected ratio -
if let dir = FileManager.default.urls(for: .documentDirectory, in: .userDomainMask).first {
let path = dir.appendingPathComponent(imageName)
let fullHTML = "" +
"" +
"" +
"" +
"" +
"" +
"" +
"
"
imgWbView.loadHTMLString(fullHTML, baseURL: nil)
}