How to convert between NSAttributedString and AttributedString

SwiftUI lacks the support for the old NSAttributedString but fully supports this new type. On the other hand, UIKit supported NSAttributedString but lacked the support of AttributedString in most APIs. Learn how to convert between the two, so you can use any of them in the platform you want.

How to use NSAttributedString in SwiftUI

Learn how to use an old NSAttributedString inside a SwiftUI app.

See all tags.