DEV Community

Cover image for LaunchNotes: Simple What's New Screens for SwiftUI Apps
Paul Contreras
Paul Contreras Subscriber

Posted on

LaunchNotes: Simple What's New Screens for SwiftUI Apps

Show What's New in Your SwiftUI App with LaunchNotes

Somewhere in the third app I shipped, I got tired of rebuilding the same "What's New" screen.
It's never quite the same codebase, so copy-pasting doesn't work. And it's not interesting
enough to engineer properly each time.

I built LaunchNotes to stop thinking about it.

One view modifier. It compares the current bundle version to what's saved in UserDefaults
and shows a sheet if something changed.

import LaunchNotes

struct ContentView: View {
    var body: some View {
        HomeView()
            .launchNotes {
                LaunchNote(
                    "New Stats",
                    "Track your progress with cleaner charts.",
                    systemImage: "chart.line.uptrend.xyaxis"
                )
                LaunchNote(
                    "Smoother Animations",
                    "The app feels faster now.",
                    systemImage: "sparkles"
                )
            }
    }
}
Enter fullscreen mode Exit fullscreen mode

You can also keep all release history in one place:

.launchNotes {
    LaunchNotesRelease("1.2.0", title: "What's New in 1.2") {
        LaunchNote("New Stats", "Cleaner progress charts.", systemImage: "chart.line.uptrend.xyaxis")
    }
    LaunchNotesRelease("1.1.0") {
        LaunchNote("Search", "Find previous sessions faster.", systemImage: "magnifyingglass")
    }
}
Enter fullscreen mode Exit fullscreen mode

There's also full-screen mode, style presets, custom accent colors, footer actions, and a
manual trigger if you don't want the automatic behavior.

.launchNotes(presentation: .fullScreen, style: .prominent) {
    LaunchNote("New Stats", "Cleaner progress charts.", systemImage: "chart.line.uptrend.xyaxis")
}
Enter fullscreen mode Exit fullscreen mode

Package is at https://github.com/pol-cova/LaunchNotes. Still early — feedback and PRs welcome.

Top comments (0)