Repository navigation
Add CHANGELOG and 3.0 migration guide #103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,39 @@ | ||
| # Changelog | ||
|
|
||
| All notable changes to this project are documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
|
|
||
| ## [Unreleased] | ||
|
|
||
| ## [3.0.0] - 2026-03-17 | ||
|
|
||
| See the [migration guide](Documentation/Migration-3.0.md) for upgrade steps. | ||
|
|
||
| ### Breaking | ||
|
|
||
| - Requires Swift 6.2 (Xcode 26) and iOS 16. | ||
| - CocoaPods support removed; the package is distributed via Swift Package Manager only. | ||
| - `Coordinator`, `DefaultCoordinator`, `ConfiguringCoordinator`, `PushCoordinator`, `ModalCoordinator`, `ShowCoordinator`, `TabBarItemCoordinator`, `CoordinatorDelegate`, `Deselectable`, `AlertCoordinator` and `ErrorAction.alertStyle()` / `alertAction()` are `@MainActor`. | ||
| - `ErrorAction.ErrorHandler` is `@MainActor @Sendable () -> Void`. | ||
|
|
||
| ### Added | ||
|
|
||
| - `Sendable` conformance for `ErrorAction`, `ErrorAction.Style`, `AlertCoordinator.Style` and `AlertCoordinator.Source`. | ||
| - `ErrorAction.title`, `action` and `style` are public. | ||
|
|
||
| ### Changed | ||
|
|
||
| - Public signatures use explicit existentials (`any CoordinatorDelegate`, `any Error`, `any Deselectable`). | ||
|
|
||
| ### Removed | ||
|
|
||
| - `Nibable` protocol. `UIView.nibName` remains available. | ||
| - `StoryboardType` and `StoryboardReference`. | ||
| - `HairlineLayoutConstraint` and `KeyboardHeightConstraint`. | ||
| - `FuntastyKitIBInspectable` library and its `UIView` IBInspectable extensions. | ||
|
|
||
| ## Earlier versions | ||
|
|
||
| See [GitHub Releases](https://github.com/futuredapp/FuntastyKit/releases) for 2.3.0 and older. | ||
|
|
||
| [Unreleased]: https://github.com/futuredapp/FuntastyKit/compare/3.0.0...HEAD | ||
| [3.0.0]: https://github.com/futuredapp/FuntastyKit/compare/2.3.0...3.0.0 | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,34 @@ | ||
| # Migrating from 2.x to 3.0 | ||
|
|
||
| 3.0 requires **Xcode 26 (Swift 6.2)** and **iOS 16**; Swift 5 language mode still works. Only the changes below require action; see the [changelog](../CHANGELOG.md) for the full list. | ||
|
|
||
| ## CocoaPods support removed | ||
|
|
||
| 3.0 is distributed via Swift Package Manager only; to stay on CocoaPods, keep `pod 'FuntastyKit', '~> 2.3'`. | ||
|
|
||
| After switching, add `import UIKit` where files use UIKit types but only import FuntastyKit. | ||
|
|
||
| ## Coordinators are `@MainActor` | ||
|
|
||
| `Coordinator` and all its sub-protocols, `CoordinatorDelegate` and `Deselectable` are now `@MainActor`. Nothing to do if your target uses default `MainActor` isolation; otherwise annotate code that creates or calls coordinators with `@MainActor`, or reach them with `await` / `Task { @MainActor in … }`. | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Might be worth a sentence on inference: a class that conforms to |
||
|
|
||
| A class that conforms to one of these protocols in its main declaration (not in an extension) becomes `@MainActor` as a whole, including its `init`, so code that creates it needs main-actor isolation too. | ||
|
|
||
| ## `ErrorAction` handlers are `@MainActor @Sendable` | ||
|
|
||
| In Swift 6 language mode, create `ErrorAction` closures in `@MainActor` code (view controllers, coordinators), and type closures you pass through as `ErrorAction.ErrorHandler`. | ||
|
|
||
| ## Removed APIs | ||
|
|
||
| | Removed | Replacement | | ||
| |---|---| | ||
| | `Nibable` | `UINib(nibName: MyView.nibName, bundle: nil).instantiate(withOwner: nil).lazy.compactMap { $0 as? MyView }.first!` | | ||
| | `StoryboardType`, `StoryboardReference` | `UIStoryboard(name:bundle:).instantiateViewController(identifier:)` | | ||
| | `HairlineLayoutConstraint` | Divide the constant by `traitCollection.displayScale` in code | | ||
| | `KeyboardHeightConstraint` | Pin to `view.keyboardLayoutGuide.topAnchor` | | ||
| | `FuntastyKitIBInspectable` | Remove the package product; set `layer` properties in code | | ||
|
|
||
| > [!WARNING] | ||
| > The compiler doesn't catch removals used from Interface Builder. Search your `.xib` and `.storyboard` files for `HairlineLayoutConstraint`, `KeyboardHeightConstraint` and the runtime attributes `borderWidth`, `borderColor` and `shadow…`. These fail silently: leftover attributes are skipped with only a console log, and leftover constraints become plain `NSLayoutConstraint`s. | ||
|
|
||
| To keep any of these as they were, copy them from [2.3.0](https://github.com/futuredapp/FuntastyKit/tree/2.3.0/Sources) into your app, add `@MainActor` to copied protocols, and change the *Module* of copied constraint classes in Interface Builder. | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Keep a Changelog recommends an
## [Unreleased]section at the top so future changes have a place to land.