### December - [Skip.tools -- Dual-platform app development in Swift](https://skip.tools/) – (Android) - [SwiftUI ScrollView Centered Items with ScrollTargetBehavior](https://articles.danielkasaj.com/swiftui-scrollview-centered-items-with-scrolltargetbehavior) - [kylehughes/PersistentKeyValueKit: Perfectly-shaped interfaces for UserDefaults and NSUbiquitiousKeyValueStore.](https://github.com/kylehughes/PersistentKeyValueKit) - [Swift Package Index](https://swiftpackageindex.com/) #### [Reclaiming storage Space from SwiftUI Preview](https://mastodon.social/@chockenberry/113703972587535736) According to Craig Hockenberry, crashed SwiftUI previews can leave behind tons of orphaned files in `~/Library/Developer/Xcode/UserData/Previews/Simulator Devices` that need to be manually cleaned up. > It looks like the best way to clean these up is using xcrun: > $ xcrun simctl --set previews delete all #### [Animate changes to numbers displayed in SwiftUI](https://mastodon.social/@Typ0genius/113657559845443126) Use the `contentTransition(.numericText())` to have the numbers animate to the new value. #### [ConnectionKage – A Swift package for monitoring reachability](https://github.com/andreilob/ConnectionKage) A lightweight wrapper around `NWPathMonitor` that provides a nice API for inspecting and monitoring network connectivity. #### [ScrollView content padding](https://mastodon.social/@Typ0genius/113718007857948330) Use `.safeAreaPadding` instead of `.padding` to inset ScrollView content while still letting it drag under the display edge. #### [SwiftUI lineLimit modifier accepts a range](https://mastodon.social/@harmash/113719502646034055) By specifying a range to the `.lineLimit` modifier, you can specify both the minimum number of lines, and the maximum number. ```swift Text("Long text that should not be truncated to a single line.") .lineLimit(2...3) ``` #### [Using TextRenderer to create highlighted text](https://alexanderweiss.dev/blog/2024-06-24-using-textrenderer-to-create-highlighted-text) From Alex Weiẞ: >  In this small post, I want to show how to create a view that enables you to highlight certain parts of a given String. Previously this was primarily done using `NSAttributedString`, but with `TextRenderer` it is now possible to do the same in a pure SwiftUI way. #### [Using SwiftUI task with an id](https://alexanderweiss.dev/blog/2023-03-05-swiftui-task-modifier) Whenever the referenced id value changes, the task will fire: ```swift struct IceCreamDetailView: View { let iceCream: IceCream let detailData: IceCreamDetails var body: some View { Text(iceCream.name) .task(id: iceCream) { // Fetch IceCream Details } } } ```