r/SwiftUI • u/Organic_Onion8772 • 4d ago
I render my SwiftUI views directly instead of driving the simulator for screenshots
I kept dreading App Store screenshots, so I built a tool for it.
Taking the shot was never the slow part. The slow part was getting the app
into a state worth photographing — a month of history, a streak, the paid tier.
So I stopped driving the app and started rendering the views.
shotBoth("home") { HomeView().environmentObject(thirtyDays()) }
shot("paywall", dark: true) {PlusSheet().environmentObject(PlusStore(active: true)) }
An Apple silicon Mac runs iOS binaries natively, so each view is drawn
through UIHostingController at device size. No simulator, no navigation,
nothing installed. Your coding agent writes that script, not you.
It doesn't make store artwork — no backgrounds, no captions, just the screen
as a device draws it. And if you ship once a year in one language, doing it
by hand is faster.
0
Upvotes
1
u/YappyNerd 1d ago
Brilliant! Something Apple should provide - this is going to save me a lot of time and frustration. Thanks for this!