Skip to content

fix(ios): exlude CDVAssetLibrary on deploymentTarget 26, add documentation - #660

Open
GitToTheHub wants to merge 1 commit into
masterfrom
pr-ios-exclude-CDVAssetLibrary-on-deploymentTarget-ios-26
Open

fix(ios): exlude CDVAssetLibrary on deploymentTarget 26, add documentation#660
GitToTheHub wants to merge 1 commit into
masterfrom
pr-ios-exclude-CDVAssetLibrary-on-deploymentTarget-ios-26

Conversation

@GitToTheHub

@GitToTheHub GitToTheHub commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Platforms affected

iOS

Motivation and Context

AssetsLibrary is deprecated since iOS 9 and unavailable when the app deployment target is iOS 26+, which causes compile failures (see #652). This code path only existed to resolve legacy asset-library://... media URLs (Photos-managed pictures/videos) via cdvfile://localhost/assets-library/.....

Apple recommends to use the PhotoKit framework, but which is not a drop-in replacement for this legacy URL model and would require broader behavior changes beyond this fix.

Therefore this PR focuses on buildability and compatibility: keep legacy behavior for lower deployment targets, and exclude the AssetsLibrary-based path for deployment target 26+.

Other changes:

  • Suppress deprecation warnings for CDVAssetLibrary.m
    • Since the class will not be included on deploymentTarget 26 these deprecation warnings don't need to be fixed.
  • Document CDVAssetLibraryFilesystem.h
  • Add documentation to README.md about asset-library://... urls

Description

Testing

Checklist

  • I've run the tests to see all new and existing tests pass
  • I added automated test coverage as appropriate for this change
  • Commit is prefixed with (platform) if this change only applies to one platform (e.g. (android))
  • If this Pull Request resolves an issue, I linked to the issue in the text above (and used the correct keyword to close issues using keywords)
  • I've updated the documentation if necessary

…mentation

- The Assets Library by Apple is deprecated since iOS 9 and removed completly when targeting iOS 26.
- Suppress deprecation warnings for `CDVAssetLibrary.m`
- Document `CDVAssetLibraryFilesystem.h`
- Add documentation to `README.md` about `asset-library://...` urls
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