WhatsNewKit
WhatsNewKit copied to clipboard
`AttributedString` example broken
What happened?
This code: https://github.com/SvenTiigi/WhatsNewKit/blob/6157c77e8be9b3d2310bc680681b61a8d9e290ac/Example/Example/ExamplesView.swift#L162-L170
Does not build with iOS 17.x in a SwiftUI app:
Cannot infer contextual base in reference to member 'cyan'
Type 'AttributeContainer' has no member 'foregroundColor'
Is there a way to highlight a word using the latest version?
What are the steps to reproduce?
Build with iOS 17.x
What is the expected behavior?
It to build.
Hi @tillkruss,
the example application is building successfully with iOS 17.X with this action run.
If you are using the code snippet included in your issue description outside the example application of the WhatsNewKit you need to ensure that the following extension is included since this extension adds a foregroundColor
static function on an AttributeContainer
https://github.com/SvenTiigi/WhatsNewKit/blob/6157c77e8be9b3d2310bc680681b61a8d9e290ac/Example/Example/ExamplesView.swift#L213-L227
Closing due inactivity. Please feel free to re-open the issue at any time.