SwiftUI Weekly - Issue #190
The curated collection of links about SwiftUI. Delivered every Monday.
Reading
What's new in Swift 6.0?
When fully enabled, Swift 6 is likely to require changes in pretty much every project.
Aligning views in different stacks in SwiftUI
While working on a SwiftUI view, I needed a way for aligning views in different stacks in a way that they are centred. The answer is to use alignment guides. If combining VStacks and HStacks does not work out, then we can take one step further and define a custom alignment for our views.
Using App Intents in a SwiftUI app
Released with iOS 16, the AppIntents
framework enables developers to extend the core functionality of an app to system services like Siri, Spotlight, Shortcut, and the new Action Button. In this way, users can use your app features almost everywhere in the system.
Composable Architecture Frequently Asked Questions
We often see articles and discussions online concerning the Composable Architecture (TCA for short) that are outdated or slightly misinformed. Often these articles and discussions focus solely on “cons” of using TCA without giving time to what “pros” are unlocked by embracing any “cons” should they still exist in the latest version of TCA.
Creating gradient on polylines in SwiftUI MapKit
When using MapKit and SwiftUI, Xcode will autocomplete to suggest you use linearGradient(_:startPoint:endPoint:options:) to style a MapPolyline. The linearGradient()
method requires you to provide a start and end point in the screen space. However, most of the time, if you are reaching for a gradient, you want it to follow the line along the map.
Formatting data as text in a Text view in SwiftUI
Learn how to format different types of data within the Text view in SwiftUI.
Videos
MVVM in SwiftUI and Insights into Crafting Coding Courses
You don’t need to use MVVM with SwiftUI.