UILabel Preview Example in project SwiftUIKitExample.xcodeproj does not work.
UILabel() // <- This is a `UIKit` view.
.swiftUIView(layout: .intrinsic) // <- This is a SwiftUI `View`.
.set(\.text, to: "Hello, UIKit!") // <- Use key paths for updates.
.fixedSize() // <- Make sure the size is set
.previewLayout(.sizeThatFits)
.previewDisplayName("UILabel Preview Example")
}
Expected to see the text "Hello, UIKit!" but that text is not visible in the preview :(
UILabel
Preview Example in projectSwiftUIKitExample.xcodeproj
does not work.Expected to see the text "Hello, UIKit!" but that text is not visible in the preview :(
https://user-images.githubusercontent.com/4176826/193900800-b6b01da1-5898-43b8-a3a8-2606e380f04c.mov
Tested with Xcode 14.0.1 and iPhone 13 (iOS 16) simulator