Swift Developments is a hand-curated newsletter containing a weekly selection of the best links, videos, tools and tutorials for people interested in designing and developing their own apps using Swift.
So have you had a good week? I certainly have! 😀 It’s been great fun digging into the new frameworks and documentation, catching up with the session videos and generally experimenting with the things. As you might expect, many around the community are doing the same so this weeks issue is unashamedly WWDC oriented and is jam-packed with articles digging into many of the new announcements. Have fun!
So we’ll get to all the WWDC news in a moment, but I wanted to kick off this week with Apple’s new Feedback Assistant tool. Announced yesterday, the new tool replaces the old Bug Reporter with a new tool designed to make providing feedback easier by automatically collecting on-device diagnostics. More details can be found here but if you do find any issues with any of the betas over the next few months, be sure to check out the new tool – it’s your best chance of getting them fixed.
Understandably SwiftUI has been getting a lot of attention this week and I like many others have been working my way through the various tutorials, documentation and videos to try and get up to speed. Apart from the documentation and official tutorials, the one great place to stop by is @twostraws‘s new SwiftUI By Example mini-site with bite-sized chunks showing you examples of building dynamic lists, adding animation and transformations, composing views and more. If you’re looking for a wider selection of material, @JuanpeCatalan has also been hard at work, pulling together a new repo with lots more great material from around the community. I’ve found this to be an extremely useful resource for getting up to speed.
You’ll have no doubt seen the great work that @stroughtonsmith has done over the last year digging it Marzipan and it’s capabilities in Mojave, but with the Marzipan Catalyst SDK now in our hands, Steve revisits the topic with a look at how we can use Catalyst to integrate our apps with the Mac and AppKit.
Whilst SwiftUI, Combine and Catalyst have grabbed the headlines, there’s a bunch of other stuff that was also announced. @BalestraPatrick has put together a useful list of tips, tricks and news covering some of the other things that you may have missed.
I always find API diffs particularly useful as they’re a great way to drill down to those areas of the APIs that have changed. @mattstevens has continued to do a great job generating the latest SDK diff and bottom line… the changes are huge!
If you’ve spent any time this week playing with SwiftUI, you’ll no doubt have seen the new
`some` keyword creep into the Swift lexicon. This has been introduced as part of SE0244 – Opaque Results Types which lets the Swift compiler limit a value to being a subclass of a particular type. To learn more, (including why it’s useful) take a look at this article from @vihanbh which goes into more depth.
Sticking with the theme of Swift Evolution Proposals make sure you also check out this new article from @twannl. Property wrappers (as discussed in SE-0258 – Property Wrappers) are a new addition to the language that let us remove a lot of boilerplate code when creating properties that are, for example, backed by UserDefaults.
Apart from the Apple announcements this week, we’ve also seen some welcome announcements from @github as well. Not only have they announced that the GitHub Package Registry will be gaining support Swift Packages, (it’s in Beta right now) but they have also announced support for generating new repositories from repository templates – templates that can then be shared with the wider community. That should help speed things up a bit.
Another new arrival this year is SF Symbols – a collection of over 1500 new symbols from Apple that you can use in your apps! It comes with its own Mac app to help browse and select the symbols your after and although the API is stringly-typed by default, the team at @piknotech have already written a useful library SFSafeSymbols to help bring some type-safety to proceedings!
It’s here! We finally have Swift Package Manager support in Xcode! Package authors wanting to create their own packages now have complete support for creating, editing and managing packages directly within Xcode! This is great news and will hopefully accelerate the use of SPM within the community. @swiftbysundell has been taking a first look.
Another brand new feature added to Xcode this year is Xcode Test Plans. These allow developers and QA engineers to configure their test suites independently of Xcode schemes and allows much greater flexibility when defining the conditions are run under as well as the order that tests are run in. @Shashikant86 has been kicking the tyres on these new features.
If like me, you raised an eyebrow at Apple’s announcement of “Find My” and it’s ability to track stolen devices even when they’re offline, then take a look at this article from @matthew_d_green which illustrates just how difficult the problem is as well as exploring some potential ideas of how the cryptography is actually working behind the scenes. As ever, no concrete details from Apple but interesting none-the-less.