-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Change pod dependencies SwiftUI
and Combine
to weak
to ensure compatibility with iOS 12
#2219
Change pod dependencies SwiftUI
and Combine
to weak
to ensure compatibility with iOS 12
#2219
Conversation
Thanks for the fix, this seems reasonable mostly reasonable to me. I wonder how much longer we need to support iOS 12 and earlier -- at some point it will make sense to drop support for those old versions, which will avoid the need for this. Looks like the build is macOS build is currently failing, so that will need to be fixed. |
Thanks! Can you think of a way to test that this works as expected within having to build and run an app on an iOS 12 simulator? I'd like to set up a test case for this in CI if possible. |
No, I'm afraid including the pod on a device or simulator actually running iOS 12 is the only way to test this... |
This PR contains the following updates: | Package | Update | Change | |---|---|---| | [airbnb/lottie-spm](https://togithub.com/airbnb/lottie-spm) | patch | `from: "4.3.3"` -> `from: "4.3.4"` | --- ### Release Notes <details> <summary>airbnb/lottie-spm (airbnb/lottie-spm)</summary> ### [`v4.3.4`](https://togithub.com/airbnb/lottie-spm/releases/tag/4.3.4) [Compare Source](https://togithub.com/airbnb/lottie-spm/compare/4.3.3...4.3.4) #### What's Changed - Fix parsing regression in 4.3.0 from addition of parsing layer effects by [@​calda](https://togithub.com/calda) in [https://github.com/airbnb/lottie-ios/pull/2208](https://togithub.com/airbnb/lottie-ios/pull/2208) - Remove old animation layer when creating a new animation layer by [@​junjielu](https://togithub.com/junjielu) in [https://github.com/airbnb/lottie-ios/pull/2214](https://togithub.com/airbnb/lottie-ios/pull/2214) - Add configuration setting to remove animated bounds changes by [@​thedrick](https://togithub.com/thedrick) in [https://github.com/airbnb/lottie-ios/pull/2218](https://togithub.com/airbnb/lottie-ios/pull/2218) - Change pod dependencies `SwiftUI` and `Combine` to `weak` to ensure compatibility with iOS 12 by [@​florianrhein](https://togithub.com/florianrhein) in [https://github.com/airbnb/lottie-ios/pull/2219](https://togithub.com/airbnb/lottie-ios/pull/2219) - Fix issue where Repeater would be ignored if not at top level by [@​calda](https://togithub.com/calda) in [https://github.com/airbnb/lottie-ios/pull/2221](https://togithub.com/airbnb/lottie-ios/pull/2221) - Replace `UIScreen.main` to get display scale on iOS 13.0 and later ([#​2215](https://togithub.com/airbnb/lottie-spm/issues/2215)) by [@​hyun99999](https://togithub.com/hyun99999) in [https://github.com/airbnb/lottie-ios/pull/2216](https://togithub.com/airbnb/lottie-ios/pull/2216) - Dispatch dot lottie file loading onto a single serial queue by [@​erichoracek](https://togithub.com/erichoracek) in [https://github.com/airbnb/lottie-ios/pull/2229](https://togithub.com/airbnb/lottie-ios/pull/2229) - Clean up unused property in InvertedMatteLayer by [@​hanton](https://togithub.com/hanton) in [https://github.com/airbnb/lottie-ios/pull/2241](https://togithub.com/airbnb/lottie-ios/pull/2241) - Fix issue where LottieView animation would restart from beginning after backgrounding app by [@​calda](https://togithub.com/calda) in [https://github.com/airbnb/lottie-ios/pull/2237](https://togithub.com/airbnb/lottie-ios/pull/2237) **Full Changelog**: airbnb/lottie-ios@4.3.3...4.3.4 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://togithub.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi4xMDAuMCIsInVwZGF0ZWRJblZlciI6IjM2LjEwMC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9--> Co-authored-by: Self-hosted Renovate Bot <361546+cgrindel-self-hosted-renovate[bot]@users.noreply.github.enterprise.com>
…ompatibility with iOS 12 (airbnb#2219)
…ompatibility with iOS 12 (airbnb#2219)
Since SwiftUI was added to lottie-ios, it no longer runs on iOS 12 devices when embedded through CocoaPods. The runtime error encountered on iOS 12:
The reason for this is, that CocoaPods automatically adds strong dependencies to any used frameworks, unless otherwise specified.
With this PR, we specifically add SwiftUI and Combine as
weak
dependencies, meaning that projects embedding lottie-ios as pod are not required to embed SwiftUI and Combine.Additionally, all files using SwiftUI are prefixed with a
canImport(SwiftUI)
.