Post

Replies

Boosts

Views

Activity

Reply to In iOS 18 beta 5 version, setting the conversion to NSAttributedString using [.documentType: NSAttributedString.DocumentType.html] occasionally causes crashes
I had also issue. I fixed it for me by replace utf8 with unicode let htmlData = NSString(string: modifiedFont).data(using: String.Encoding.unicode.rawValue) ?? Data() let options: [NSAttributedString.DocumentReadingOptionKey: Any] = [ .documentType: NSAttributedString.DocumentType.html, .characterEncoding: String.Encoding.unicode.rawValue, ]
4w