Skip to content

Restore NukeExtensions as its own module - #1038

Merged
kean merged 1 commit into
mainfrom
revert/fold-nuke-extensions
Oct 11, 2026
Merged

kean merged 1 commit into
mainfrom
revert/fold-nuke-extensions

Conversation

@kean

@kean kean commented Oct 11, 2026

Copy link
Copy Markdown
Owner

Reverts #947. NukeExtensions is its own module again, with the image view extensions, ImageLoadingOptions, and ImageDisplaying. The plan is a more modern set of these APIs in NukeUI that replaces them, with NukeExtensions deprecated later; for now it's only soft-deprecated, so no @available attributes.

Not a mechanical revert

git revert -m 1 conflicts in seven files and doesn't compile, because #958 and the work after it were written against the folded layout:

  • Kept the AVKit fix. The first commit of Fold NukeExtensions into NukeUI #947 removes an unused AVKit import from Nuke. It is separable and reverting it would put AV frameworks back in every app's link line, so it stays, with its CHANGELOG line.
  • The module graph. NukeExtensions depends on NukeUI (so that loading into an AnimatedImageView plays the animation), as the shim already did. NukeUI no longer depends on ImageDisplaying: LazyImageView calls AnimatedImageView.display(_:) directly, and a package displayContainer(_:) is the one seam NukeExtensions uses. That needs SWIFT_PACKAGE_NAME = Nuke on the NukeExtensions target, which Nuke and NukeUI already have.
  • Docs and tests written after Fold NukeExtensions into NukeUI #947 move back. uikit.md and objective-c.md say NukeExtensions again; the "Folded into NukeUI" migration guide section, README row, and CHANGELOG entry are gone. ImageViewExtensionsReuseTests and the three "load into an AnimatedImageView" tests move to NukeExtensionsTests. The re-export-of-NukeUI test is removed. request(id:) and runWhileMainThreadIsBlocked are not specific to the extensions and move to Tests/Helpers.
  • Wiring. NukeExtensions.docc, the Demo (links and imports NukeExtensions), the snippets package, and Nuke.xcodeproj.
  • Kept as is. Tests that main deleted after Fold NukeExtensions into NukeUI #947 stay deleted, and README says LazyImageView where it said ImageView.

To test

  1. make ci-ios-ui ci-tvos ci-macos: NukeExtensionsTests 70/71/59 and NukeUITests 512/512/505 pass (the suites hold 591 @Tests, one fewer than main: the removed re-export test).
  2. make ci-platforms: all three modules on watchOS and visionOS, the Demo, the SPM build, and the snippets package.
  3. NukePerformanceTests builds for testing. DocC builds for NukeExtensions.

Note for proto/image-loading-target: it removes ImageDisplaying from NukeUI's ImageViewExtensions.swift, so it needs a rebase onto this.

Reverts the fold of NukeExtensions into NukeUI (#947), keeping its
separate AVKit import fix.

NukeExtensions keeps the image view extensions, ImageLoadingOptions, and
the ImageDisplaying protocol. It depends on NukeUI so that loading into
an AnimatedImageView plays the animation. NukeUI no longer depends on
ImageDisplaying: LazyImageView calls AnimatedImageView directly, and a
package-level displayContainer(_:) is the one seam NukeExtensions uses.

Beyond the mechanical revert, everything written against the folded
layout after #947 moves back: the docs and the migration guide, the
article and snippet samples, the Demo app, and the tests and helpers.
@kean
kean merged commit 658fdab into main Oct 11, 2026
6 checks passed
@kean kean mentioned this pull request Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant