A Swift Package to easily showcase your new app features.
It's designed from the ground up to be fully customized to your needs.
This is Lickability's fork of WhatsNewKit by Sven Tiigi. Version 3.0.0 introduces breaking API changes and requires iOS 26, macOS 26, or visionOS 26. Version 3.1.0 adds a reusable release history screen. See the latest release notes and migration guidance before upgrading.
import SwiftUI
import WhatsNewKit
struct ContentView: View {
var body: some View {
NavigationView {
// ...
}
.whatsNewSheet()
}
}- Easily present your new app features π€©
- Automatic & Manual presentation mode β
- Support for SwiftUI, UIKit and AppKit π§βπ¨
- Runs on iOS, macOS and visionOS π± π₯ π
- Adjustable layout π§
- iOS 26 or later, macOS 26 or later, or visionOS 26 or later.
- Xcode 26 or later. The package and example use Swift 6 language mode (Swift tools 6.0 or later).
This raises the minimum supported versions from iOS 13 to iOS 26, macOS 11 to macOS 26, and visionOS 1 to visionOS 26. Applications supporting earlier systems must remain on an earlier release.
UI callbacks (PrimaryAction.onDismiss, SecondaryAction.Action.custom), feature image builders, haptic execution, and WhatsNewView are main-actor isolated. Create and use views from a main-actor context; callbacks can directly access main-actor UI state. The old Binding<PresentationMode> callback remains available with a deprecation warning; migrate to .perform { dismiss in ... }.
WhatsNew.Version and WhatsNew.Layout are Sendable. WhatsNew.Layout.default is immutable; customize a local copy and pass it to a view or WhatsNewEnvironment(defaultLayout:) instead of mutating a global setting.
InMemoryWhatsNewVersionStore.shared belongs to the main actor. Independently created stores remain ordinary synchronous objects owned by their caller; they are not Sendable. Version store protocols remain synchronous and do not require actor isolation or Sendable conformance from custom implementations.
WhatsNewEnvironment.Key.defaultValue is now read-only and creates an independent default environment. Replace direct assignments to that key with .environment(\.whatsNew, yourEnvironment). WhatsNewEnvironment remains open for subclassing; environments and UI models containing views or closures are not declared Sendable.
CI uses the xcode-27 runner and selects the latest installed Xcode with setup-xcode (latest, including beta releases). It runs the package tests on the latest installed iOS runtime and macOS, builds the package for visionOS, and builds the example for all three platforms. Package and workflow changes trigger these checks.
Run the macOS package tests with swift test. To run iOS tests locally, choose an installed iOS 26 or newer simulator:
xcodebuild test -scheme WhatsNewKit -destination 'platform=iOS Simulator,name=iPhone 17,OS=latest'The example requires iOS 26, macOS 26, or visionOS 26. Open Example/Example.xcodeproj and select the Example scheme.
To integrate using Apple's Swift Package Manager, add the following as a dependency to your Package.swift:
dependencies: [
.package(url: "https://github.com/Lickability/WhatsNewKit.git", from: "3.1.0")
]In Xcode, choose File > Add Package Dependencies, enter https://github.com/Lickability/WhatsNewKit.git, and select Up to Next Major Version starting at 3.1.0. When migrating from upstream, replace the existing package dependency with this fork; keep the WhatsNewKit product and import.
The version requirement resolves after the 3.1.0 tag is published. See Releasing for the maintainer steps.
Check out the example application to see WhatsNewKit in action. Simply open the Example/Example.xcodeproj and run the "Example" scheme.
Captured on the iPhone 18 Pro simulator running iOS 27.2 at the default text size.
- Manual Presentation
- Automatic Presentation
- WhatsNewEnvironment
- WhatsNewVersionStore
- WhatsNew
- Release History
- Layout
- WhatsNewViewController
If you wish to manually present a WhatsNewView you can make use of the sheet(whatsNew:) modifier.
struct ContentView: View {
@State
var whatsNew: WhatsNew? = WhatsNew(
title: "WhatsNewKit",
features: [
.init(
image: .init(
systemName: "star.fill",
foregroundColor: .orange
),
title: "Showcase your new App Features",
subtitle: "Present your new app features..."
),
// ...
]
)
var body: some View {
NavigationView {
// ...
}
.sheet(
whatsNew: self.$whatsNew
)
}
}Use WhatsNewHistoryView in Settings to show a scrolling list of version updates. It reuses the same WhatsNew models and feature rows as the launch sheet, including attributed text and features without subtitles.
NavigationLink("Release Notes") {
WhatsNewHistoryView(whatsNewCollection: releases)
.navigationTitle("Release Notes")
}Pass releases in display order (usually newest first). Headings default to 1.2.3 (456): marketing version, then build number. WhatsNew(title:features:) reads both values from the main bundle. Archive each shipped update with an explicit version and buildNumber, for example WhatsNew(version: "1.2.3", buildNumber: "456", title: "Whatβs New", features: features). Historical entries with no known build show only their marketing version. Multiple builds of the same marketing version can appear as separate entries. The history does not mark updates as seen, present notices, or run primary or secondary actions. It owns neither a navigation stack nor a dismissal button, so it can be pushed from Settings or embedded in your own sheet.
Customize version headings when your app uses a different version format:
WhatsNewHistoryView(whatsNewCollection: releases) { release in
Text("Version \(release.version.description)")
}
.navigationTitle("Updates")At accessibility text sizes, both the history and launch sheet place feature icons above their text to preserve reading width.
The automatic presentation mode allows you to simply declare your new features via the SwiftUI Environment and WhatsNewKit will take care to present the corresponding WhatsNewView.
First add a .whatsNewSheet() modifier to the view where the WhatsNewView should be presented on.
struct ContentView: View {
var body: some View {
NavigationView {
// ...
}
// Automatically present a WhatsNewView, if needed.
// The WhatsNew that should be presented to the user
// is automatically retrieved from the `WhatsNewEnvironment`
.whatsNewSheet()
}
}The .whatsNewSheet() modifier is making use of the WhatsNewEnvironment to retrieve an optional WhatsNew object that should be presented to the user for the current version. Therefore you can easily configure the WhatsNewEnvironment via the environment modifier.
extension App: SwiftUI.App {
var body: some Scene {
WindowGroup {
ContentView()
.environment(
\.whatsNew,
WhatsNewEnvironment(
// Specify in which way the presented WhatsNew Versions are stored.
// In default the `UserDefaultsWhatsNewVersionStore` is used.
versionStore: UserDefaultsWhatsNewVersionStore(),
// Pass a `WhatsNewCollectionProvider` or an array of WhatsNew instances
whatsNewCollection: self
)
)
}
}
}
// MARK: - App+WhatsNewCollectionProvider
extension App: WhatsNewCollectionProvider {
/// Declare your WhatsNew instances per version
var whatsNewCollection: WhatsNewCollection {
WhatsNew(
version: "1.0.0",
// ...
)
WhatsNew(
version: "1.1.0",
// ...
)
WhatsNew(
version: "1.2.0",
// ...
)
}
}The WhatsNewEnvironment will take care to determine the matching WhatsNew object that should be presented to the user for the current version.
As seen in the previous example you can initialize a WhatsNewEnvironment by specifying the WhatsNewVersionStore and providing a WhatsNewCollection.
// Initialize WhatsNewEnvironment by passing an array of WhatsNew Instances.
// UserDefaultsWhatsNewVersionStore is used as default WhatsNewVersionStore
let whatsNewEnvironment = WhatsNewEnvironment(
whatsNewCollection: [
WhatsNew(
version: "1.0.0",
// ...
)
]
)
// Initialize WhatsNewEnvironment with NSUbiquitousKeyValueWhatsNewVersionStore
// which stores the presented versions in iCloud.
// WhatsNewCollection is provided by a `WhatsNewBuilder` closure
let whatsNewEnvironment = WhatsNewEnvironment(
versionStore: NSUbiquitousKeyValueWhatsNewVersionStore(),
whatsNewCollection: {
WhatsNew(
version: "1.0.0",
// ...
)
}
)Additionally, the WhatsNewEnvironment includes a fallback for patch versions. For example when a user installs version 1.0.1 and you only have declared a WhatsNew for version 1.0.0 the environment will automatically fallback to version 1.0.0 and present the WhatsNewView to the user if needed.
If you wish to further customize the behaviour of the WhatsNewEnvironment you can easily subclass it and override the whatsNew() function.
class MyCustomWhatsNewEnvironment: WhatsNewEnvironment {
/// Retrieve a WhatsNew that should be presented to the user, if available.
override func whatsNew() -> WhatsNew? {
// The current version
let currentVersion = self.currentVersion
// Your declared WhatsNew objects
let whatsNewCollection = self.whatsNewCollection
// The WhatsNewVersionStore used to determine the already presented versions
let versionStore = self.whatsNewVersionStore
// TODO: Determine WhatsNew that should be presented to the user...
}
}A WhatsNewVersionStore is a protocol type which is responsible for saving and retrieving versions that have been presented to the user.
let whatsNewVersionStore: WhatsNewVersionStore
// Save presented versions
whatsNewVersionStore.save(presentedVersion: "1.0.0")
// Retrieve presented versions
let presentedVersions = whatsNewVersionStore.presentedVersions
// Retrieve bool value if a given version has already been presented
let hasPresented = whatsNewVersionStore.hasPresented("1.0.0")WhatsNewKit comes along with three predefined implementations:
// Persists presented versions in the UserDefaults
let userDefaultsWhatsNewVersionStore = UserDefaultsWhatsNewVersionStore()
// Persists presented versions in iCloud using the NSUbiquitousKeyValueStore
let ubiquitousKeyValueWhatsNewVersionStore = NSUbiquitousKeyValueWhatsNewVersionStore()
// Stores presented versions in memory. Perfect for testing purposes
let inMemoryWhatsNewVersionStore = InMemoryWhatsNewVersionStore()If you already have a specific implementation to store user related settings like Realm or Core Data you can easily adopt your existing implementation to the WhatsNewVersionStore protocol.
If you are making use of the NSUbiquitousKeyValueWhatsNewVersionStore please ensure to enable the iCloud Key-value storage capability in the "Signing & Capabilities" section of your Xcode project.
The following sections explains how a WhatsNew struct can be initialized in order to describe the new features for a given version of your app.
let whatsnew = WhatsNew(
// The Version that relates to the features you want to showcase
version: "1.0.0",
// The title that is shown at the top
title: "What's New",
// The features you want to showcase
features: [
WhatsNew.Feature(
image: .init(systemName: "star.fill"),
title: "Title",
subtitle: "Subtitle"
)
],
// The primary action that is used to dismiss the WhatsNewView
primaryAction: WhatsNew.PrimaryAction(
title: "Continue",
tint: .accentColor,
hapticFeedback: .notification(.success),
onDismiss: {
print("WhatsNewView has been dismissed")
}
),
// The optional secondary action that is displayed above the primary action
secondaryAction: WhatsNew.SecondaryAction(
title: "Learn more",
foregroundColor: .accentColor,
hapticFeedback: .selection,
action: .openURL(
.init(string: "https://github.com/Lickability/WhatsNewKit")
)
)
)The WhatsNew.Version specifies the version that has introduced certain features to your app.
// Initialize with major, minor, and patch
let version = WhatsNew.Version(
major: 1,
minor: 0,
patch: 0
)
// Initialize by string literal
let version: WhatsNew.Version = "1.0.0"
// Initialize WhatsNew Version by using the current version of your bundle
let version: WhatsNew.Version = .current()A WhatsNew.Title represents the title text that is rendered above the features.
// Initialize by string literal
let title: WhatsNew.Title = "Continue"
// Initialize with text and foreground color
let title = WhatsNew.Title(
text: "Continue",
foregroundColor: .primary
)
// On >= iOS 15 initialize with AttributedString using Markdown
let title = WhatsNew.Title(
text: try AttributedString(
markdown: "What's **New**"
)
)A WhatsNew.Feature describe a specific feature of your app and generally consist of an image, title, and subtitle.
let feature = WhatsNew.Feature(
image: .init(
systemName: "wand.and.stars"
),
title: "New Design",
subtitle: .init(
try AttributedString(
markdown: "An awesome new _Design_"
)
)
)Omit subtitle (or pass nil or empty text) for a title-only feature. It uses regular Body text; a feature with a description uses a semibold Body title and regular Body description.
The WhatsNew.PrimaryAction allows you to configure the behaviour of the primary button which is used to dismiss the presented WhatsNewView
The label uses the native button style's foreground by default. For custom tints that need a contrasting label, supply foregroundColor, for example PrimaryAction(tint: .white, foregroundColor: .black). Choose colors that remain readable in each supported appearance.
let primaryAction = WhatsNew.PrimaryAction(
title: "Continue",
tint: .blue,
hapticFeedback: .notification(.success),
onDismiss: {
print("WhatsNewView has been dismissed")
}
)Note: HapticFeedback will only be executed on iOS
Add optional supplemental text, such as a privacy notice, below the features. Short notices sit near the bottom of the content; longer notices scroll so they remain readable at accessibility text sizes. Attributed text can include links.
let notice = WhatsNew.Notice(
image: .init(systemName: "hand.raised.fill", foregroundColor: .blue),
text: .init(try AttributedString(markdown: "Learn how we handle your information in our [privacy policy](https://example.com/privacy)."))
)
// Pass notice: notice to WhatsNew's initializer.A WhatsNew.SecondaryAction which is displayed above the WhatsNew.PrimaryAction can be optionally supplied when initializing a WhatsNew instance and allows you to present an additional View, perform a custom action or open an URL.
// SecondaryAction that presents a View
let secondaryActionPresentAboutView = WhatsNew.SecondaryAction(
title: "Learn more",
foregroundColor: .blue,
hapticFeedback: .selection,
action: .present {
AboutView()
}
)
// SecondaryAction that opens a URL
let secondaryActionOpenURL = WhatsNew.SecondaryAction(
title: "Read more",
foregroundColor: .blue,
hapticFeedback: .selection,
action: .openURL(
.init(string: "https://github.com/Lickability/WhatsNewKit")
)
)
// SecondaryAction with custom execution
let secondaryActionCustom = WhatsNew.SecondaryAction(
title: "Custom",
action: .perform { dismiss in
// Perform your action, then optionally dismiss the release notes.
dismiss()
}
)Note: HapticFeedback will only be executed on iOS
Use .perform { dismiss in ... } for custom secondary actions. The callback receives SwiftUI's DismissAction for the release-notes presentation. Replace presentationMode.wrappedValue.dismiss() with dismiss(). The old .custom callback is deprecated but still supported. If you switch over SecondaryAction.Action, handle its new perform, dismiss, and openURL cases.
.openURL uses SwiftUI's openURL environment action, so an app can intercept or replace URL handling. A nil URL does nothing. .dismiss closes the release notes; dismissing a view shown with .present closes only that secondary sheet.
The manual and automatic sheet modifiers record the version when the outer sheet finishes dismissing, before invoking their onDismiss callback. Continue, custom dismissal, swipe dismissal, and clearing the bound item all use that completion path. Opening or closing secondary content does not record the version. The manual modifier stays attached while its item changes, preserving the presenting view's state. Automatic presentation reads the current environment until the sheet is dismissed, so release notes supplied after the view first appears can still be presented. After dismissal, it stays suppressed for that modifier's lifetime.
PrimaryAction.onDismiss retains its existing behavior: it runs immediately when the primary button requests dismissal, before the animation completes. It does not run for a swipe or secondary action. Use the sheet modifier's onDismiss for work that must wait for dismissal completion.
When embedding WhatsNewView directly or using WhatsNewViewController, version recording follows the view's presentation/disappearance lifecycle; its own secondary sheet is excluded from disappearance-based recording. Use the supplied sheet modifiers when you need the explicit completion callback.
WhatsNewKit allows you to adjust the layout of a presented WhatsNewView in various ways.
The default presentation uses a compact leading title, top-aligned feature symbols, and a native capsule action. Content and actions fill the available width with 32-point horizontal padding. On macOS, sheets start at an ideal size of 560 Γ 640 points and remain resizable through native fitted presentation sizing. The bottom action bar reserves its own space with safeAreaBar on all supported platforms. The primary button uses the native prominent glass style on iOS and macOS and the native bordered prominent style on visionOS.
Typography uses public SwiftUI semantic styles: Title 2 bold for the compact heading, Body semibold for feature titles with descriptions and the primary action, and Body regular for descriptions and title-only features. The primary button has a 44-point minimum height and grows with its content. Only the primary action caps Dynamic Type at .accessibility4; the rest of the content continues through .accessibility5. The fonts and scaling follow the measured standard OnBoardingKit configuration on iOS 27.2; the 44-point button minimum is a deliberate visual adjustment from its measured 52-point minimum. Other platforms use their native semantic font metrics. Supplemental notices retain their separate caption styling.
This redesign changes the public styling API:
- Replace
PrimaryAction(backgroundColor:foregroundColor:)withPrimaryAction(tint:). SwiftUI supplies the button's shape, pressed appearance, and default foreground. In 3.1.0 and later, an optionalforegroundColorcan override the label color for custom tints. - Use
contentPaddingfor the title and feature content, andfooterPaddingfor the actions.featureListPaddingandfooterVisualEffectViewPaddingare removed. scrollViewBottomContentInsetis removed: the bottom bar reserves space automatically.featureHorizontalAlignmentandfooterPrimaryActionButtonCornerRadiusare removed. Feature icons are top aligned and the primary action is a native capsule.- Use
featureImageWidthto size the icon column.
Create a layout, then pass it to the environment or an individual presentation. The standard WhatsNew.Layout.default is immutable.
var layout = WhatsNew.Layout.default
layout.featureListSpacing = 35When using the automatic presentation style you can supply a default layout when initializing the WhatsNewEnvironment.
.environment(
\.whatsNew,
.init(
defaultLayout: layout,
whatsNewCollection: self
)
)Alternatively you can pass a WhatsNew.Layout when automatically or manually presenting the WhatsNewView
.whatsNewSheet(
layout: WhatsNew.Layout(
contentPadding: .init(
top: 80,
leading: 0,
bottom: 0,
trailing: 0
)
)
).sheet(
whatsNew: self.$whatsNew,
layout: WhatsNew.Layout(
footerActionSpacing: 20
)
)When using UIKit or AppKit you can make use of the WhatsNewViewController.
let whatsNewViewController = WhatsNewViewController(
whatsNew: WhatsNew(
version: "1.0.0",
// ...
),
layout: WhatsNew.Layout(
contentSpacing: 80
)
)If you wish to present a WhatsNewViewController only if the version of the WhatsNew instance has not been presented you can make use of the convenience failable initializer.
// Verify WhatsNewViewController is available for presentation
guard let whatsNewViewController = WhatsNewViewController(
whatsNew: WhatsNew(
version: "1.0.0",
// ...
),
versionStore: UserDefaultsWhatsNewVersionStore()
) else {
// Version of WhatsNew has already been presented
return
}
// Present WhatsNewViewController
// Version will be automatically saved in the provided
// WhatsNewVersionStore when the WhatsNewViewController gets dismissed
self.present(whatsNewViewController, animated: true)




