davdroman/PeriodDuration: The ISO 8601 period/duration types missing in Foundation
The ISO 8601 period/duration types missing in Foundation - GitHub - davdroman/PeriodDuration: The ISO 8601 period/duration types missing in Foundation
The ISO 8601 period/duration types missing in Foundation - GitHub - davdroman/PeriodDuration: The ISO 8601 period/duration types missing in Foundation
Recently I’ve been using Swift Playground app on iPad for studying Swift language. Personally, I think the playground app is one of the best apps for learning swift. While writing swift code is enough, there are sometimes to write UI related code. Here is how to use swift playground live view to show view.
I recently read the book Domain modeling made functional by Scott Wlaschin. Great book, highly recommend it. There is a whole chapter dedicated to integrity and consistency inside business domains…
Mobile applications are often viewed as secure storage by developers. They are not, you should never store sensitive keys hard-coded inside mobile app.
Learn how to create an outline button style.
Combine is a powerful tool to deal with streams in IOS, it keeps streaming data until it either errors out or is told to finish. However in some cases, we do not want the streaming to end when something errors out, this article will show a way to achieve that.
Apple made a subtle change to the stack view implementation in iOS 15 that might catch you out when deploying back to earlier iOS versions.
In iOS 15 you can set limits on the minimum and maximum sizes of dynamic type.
The thing you should know before using the convertFromSnakeCase decoding strategy.
Learn how actors in Swift can help developers to identify data races during development time and prevent them from happening once and for all.
List views are a staple of iOS UIs. Learn how SwiftUI makes implementing them super easy.
It might not be obvious that we can create a custom environment value, but we can do that. The steps to create one are not as straightforward as we usually do, but it isn't hard if you know how to do it.
Learn about developing mobile apps with an accessibility mindset and the strategies, best practices, and tools that can help software engineering teams create more accessible mobile products.
We [explored](https://kristaps.me/blog/swiftui-mapview/) the Mapview in SwiftUI a while back. This time we will look into creating custom map annotations, the limitations, and how to overcome some of them. Placing annotations on the map, like marking a specific place, is one of the most critical tasks when showing a map in our iOS applications.
The Swift concurrency roadmap was first outlined in a post to the Swift forums in October 2020, with its stated goal being to “make concurrent programming in Swift convenient, efficient, and safe”…
SwiftUI became very powerful during the last WWDC. We gained many new features, and one of them was a brand new FocusState property wrapper. FocusState property wrapper allows us to read and write the current focus position in the view hierarchy. This week we will learn how to manage focus in SwiftUI apps using FocusState property wrapper and focused view modifier.
Apple gave buttons a big upgrade in iOS 15.
Damn cool ❤️
A collection of tools for debugging, diffing, and testing your application's data structures. - GitHub - pointfreeco/swift-custom-dump: A collection of tools for debugging, diffing, and testing your application's data structures.
Learn how to make network requests using async/await in Swift, and also find out what are the benefits it brings.
A tip shared by Ole Begemann some time ago to check if your workarounds in Swift have been fixed has been super helpful. With Swift, the compiler helps you out a bunch — why not use that to make sure you check if certain bugs have been fixed in newer versions of the language or the operating system? Given the following workaround for an imaginary issue in iOS 14.4: func workaroundForIssue(_ string: String) -> String { // Oh noes; "hello" does not return "world" in iOS 14.4! if #available(iOS 14.4, *), string == "hello" { return "world" } else { return string } } We’d want to check if this issue has been fixed in iOS 14.5 or later: @available(iOS, deprecated: 14.5, message: """ If this returns 'world' as expected, please update the function to only include the workaround in those versions that require it. If the issue has not been resolved yet, please update the deprecated version to the next minor release. """) func workaroundForIssue(_ string: String) -> String { // Oh noes; "hello" does not return "world" in iOS 14.4! if #available(iOS 14.4, *), string == "hello" { return "world" } else { return string } } This will emit a compiler warning once you’d update to a version of Xcode that supports iOS 14.5 or later. … if it hasn’t yet been fixed in that new version, make sure to update the “deprecated” version, and don’t forget to update your Feedback either ;-) Assuming the issue was fixed in that newer version, update the function to only include the workaround in those versions that require it: func workaroundForIssue(_ string: String) -> String { if #available(iOS 14.5, *) { return string } else if #available(iOS 14.4, *), string == "hello" { // Oh noes; "hello" does not return "world" in iOS 14.4! return "world" } else { return string } } Oh, and as mentioned by Peter Steinberger, you’ll unfortunately not be able to use this trick as-is for Objective-C; you’d have to work around the issue in Swift, and expose that to Objective-C, which you may not always be able to (or want to) do.