I have a html data in my label, and how to make them clickable.
I can show my html data successful, but I don't know how to convert them.
Have any good suggestion to me?
Thanks
This is my label code:
let htmlData = ""
do {
        let attrStr = try NSAttributedString(
            data: htmlData.data(using: String.Encoding.unicode, allowLossyConversion: true)!,
            options: [ NSDocumentTypeDocumentAttribute: NSHTMLTextDocumentType],
            documentAttributes: nil)
        self.label.attributedText = attrStr
    } catch let error {
        print(error)
    }

 
    