Type Safely

Type Safely

Share this post

Type Safely
Type Safely
Using CustomReflectable To Debug a SwiftUI View Whenever It Refreshes

Using CustomReflectable To Debug a SwiftUI View Whenever It Refreshes

Daily Coding Tip 109

Millie Sturgeon's avatar
Millie Sturgeon
Jun 15, 2022
∙ Paid

Share this post

Type Safely
Type Safely
Using CustomReflectable To Debug a SwiftUI View Whenever It Refreshes
Share
Image by Rene Gossner from Pixabay

When you print the value of a variable, you don’t necessarily get useful information. I created a SwiftUI app project called PrintChanges. If I try to print the value of ContentView, the default View, all I get back is PrintChanges.ContentView.

I can call dump(self), but this gives me far too much information.

There is …

Keep reading with a 7-day free trial

Subscribe to Type Safely to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2025 Type Safely
Privacy ∙ Terms ∙ Collection notice
Start writingGet the app
Substack is the home for great culture

Share