We're seeing the same results on our current, unreleased project. Its very concerning and we're considering switching to ARKit instead just because of this.
Post
Replies
Boosts
Views
Activity
What activity type is used? The location manager will only update the location when a significant change is detected. This is intended behaviour to save battery life and depends on the activity type set.
iAds is entirely deprecated. To quote the documentation:
After February 7, 2023, all requests made to the Apple Search Ads iAd Attribution API will return with a value of "iad-attribution" = false, or errors. See requestAttributionDetails(_:). Use the AdServices framework for current attribution integration with the Apple Search Ads Campaign Management API for devices using iOS 14.3 and later. Attribution isn’t available for downloads and redownloads from devices using iOS 14.2 or earlier.
As far as I know it is not allowed. Which version had this working?
Structs are not a thing in Objective-C hence why you cannot add @objc to your function.
The "real" solution is to use a Coordinator class to handle this (see makeCoordinator in the documentation.
Two other alternatives to consider:
Create a UIView with the WKWebView and selector inside, or
Subclass WKWebView and add both your refresh control and selector inside
The reason for your troubles is due to your SwiftUI "view" not really being a view, but a representation of what will become your view. The actual view that is rendered on screen may be a different instance. This is where the Coordinator comes in because it it persisted throughout your "view's" lifetime and passed between instances.
You should receive a runtime warning about updating your data when you do this:
DispatchQueue.main.async {
self.extractedContent = extractedData
}
Try with this instead
Task { @MainActor in
self.extractedContent = extractedData
}