Conferences Condensed: WWDC20
Our favorite sessions from this year
We look forward to WWDC every year, and we know you do, too. As much as we missed seeing all of our pals in San Jose for the conference, we still had a great time watching sessions online and chatting with familiar faces and new friends in our Discord. Keep reading to hear a bit about some of our favorite videos this year.
Advances in UICollectionView
So much of what we do on a daily basis involves the meticulous formatting of data to look great in performant scrolling lists. Several of this year‘s WWDC sessions focused on new technologies that make that possible in both UIKit
and SwiftUI
, and I couldn‘t be happier. Advances in UICollectionView provides a great overview of the new technologies that enable enhancements to lists in UIKit
. Hello UICollectionViewListCell
and goodbye UITableView
. You‘ll definitely want to bookmark all of the 2020 sessions referenced in the session for a deeper dive: Advances in diffable data sources, Lists in UICollectionView, and Modern cell configuration.
— Michael Liberatore
Add custom views and modifiers to the Xcode Library
The promise of adding custom views to the Xcode Library goes way back to Xcode 3 with Interface Builder plugins. But this year, Apple brought that idea to SwiftUI via two new protocols called LibraryContentProvider
and LibraryItem
.
No longer will we toil trying to get @IBInspectable
to work as intended. Now it’s so simple to create a new SwiftUI view and have it show up with sample data right inside the Xcode Library. But Apple didn’t stop at views—they even made it possible to expose custom Modifiers as well. As Anton, the talk’s presenter, put it, this will allow us to discover and learn about all the controls in our apps‘ design systems much more easily and visually than just reading the source code.
— mb Bischoff
Build trust through better privacy
This was a great presentation on how Apple handles user privacy. The talk goes over the four key pillars of privacy, what they mean, and how you can implement those best practices into your app to build trust with your users. Here are a few of my takeaways:
On-device processing
- When user data is sent off-device for processing, a user loses control over that data
- Apple is continuing to improve Core ML to integrate machine learning models into your app, to keep processing on-device rather than on a server
- Taking advantage of the tools Apple provides is a good way to minimize the data that is processed off-device
Data minimization
- We should aim to show respect for a user‘s data and ask for as little of it as possible—only ask for what you need
- Again, Apple is providing new tools to make this easier
- Limited Photos Library: a user can define which photos they want to share, instead of sharing all of their photos
- Share approximate location, rather than exact location
- QuickType to suggest contact details, rather than asking for access to all user contacts
- Limited access doesn‘t mean limited functionality
Security protections
- Apple is adding Encrypted DNS protocols that are natively supported
Transparency and control
- Put users in control of their data
- Inform users about when, how, and why their data is being collected
- Updates to the App Store Product Page can let users easily see what data an app collects before downloading
- You also need to declare this for any third-party SDKs you use
— Tom DeVuono
Embrace Swift type inference
Leveraging type inference is a fundamental way to learn about generics in Swift. Often we can overlook ways to compose objects in a large project—type inference allows us to omit explicit type annotations without compromising type safety. This is also why we can create complex interfaces within SwiftUI with just a few lines of code, since it relies heavily on type inference at the call sites.
I really appreciated the speaker’s cadence in this talk, since this concept dives into how the Swift compiler infers concrete types without explicitly specifying them.
— Daisy Ramos