3 min read

Issue #50 ๐Ÿ‘‘

Hi there, welcome to the 50th issue of iOS Code Review, and happy WWDC week! I hope you're not too overwhelmed. Please enjoy today's issue which doesn't talk about what's new this year ๐Ÿ˜

๐Ÿ’Ž Sponsor of the week - Bitrise

Last year Bitrise launched Mobile DevOps Assessment survey to the mobile app developer world. The results are in!
You can find answers to popular questions like โ€˜what percentage of teams use code generation toolsโ€™. Download the report to receive the results, as well as lots of free resources on Mobile DevOps!

Download free report

Happy WWDC!

I will share my favorites from WWDC 2023 at a later point - but for now, here are notable things available from iOS 15 that are a must for modern UIKit apps ๐Ÿ˜‹

Bar appearance

Definition-based configuration for different states of the UINavigationBar: standardAppearance, compactAppearance, ย scrollEdgeAppearance, compactScrollEdgeAppearance. And there's a similar comnfiguration available for UITabbBar ๐Ÿ™‚

UIButton styling

Definition-based configuring of the UIButtons, so making a capsule button is almost as easy as in SwiftUI using UIButton.Configuration:

https://useyourloaf.com/blog/button-configuration-in-ios-15/

No cell subclassing

It's not necessary anymore to subclass system cells - configurationUpdateHandler lets us hook into state updates and update the cell's appearance. This fits well with the contentConfiguration and backgroundConfiguration of the cell - which again, make configuring cells as declarative as it can get in UIKit ๐Ÿ˜‹ And of course, this is available for both UITableView and UICollectionView.

If we need to make a custom-designed cell, then we can dive into content views - a new way to provide the custom content for the cell. A content view works with a contentConfiguration - and again, it doesn't require subclassing of UITableViewCell/UICollectionViewCell. To learn about it, you can follow Apple's official interactive tutorial:

Using content views | Apple Developer Documentation
In this tutorial, youโ€™ll add capabilities to the appโ€™s editing mode that transform a view-only list of reminder details into editable controls.

Structural identity in SwiftUI

Structural identity is how SwiftUI understands your view hierarchy and recognizes particular views without specific identifiers. It is crucial to understand how it works to build great and performant views with SwiftUI:

Structural identity in SwiftUI
Structural identity is the type of identity that SwiftUI uses to understand your views without an explicit identifier by using your layout description. This week we will learn how to improve performance and eliminate unwanted animations by using inert view modifiers in SwiftUI.

And more...

For some less technical reading, my husband David has started a blog where he writes about the tech industry. He's been supporting me throughout my carreer journey, and I can only return the favour ๐Ÿ™‚ If you're curious to read about the challenges of running a startup, or how we can fix the state of hiring, check out his writing:

The Flawed Dance of Recruitment: Breaking the Cycle for a Better Hiring Process
Introduction
The Silent Killer of Startups: How a Lack of Inspiration Destroys Your Team and Business
In this post, I summarise a decade of my experience, analyse problems that I encountered in every company I worked with andโ€ฆ

โœŒ๏ธ
Alright, that's it for today!
Thank you to Bitrise for sponsoring this issue โค๏ธ
I'm curious if you found any of the tips particularly interesting - let me know by replying to this email!