Posts

Post marked as solved
2 Replies
596 Views
Hello, I am fetching and displaying the .fullalbums for an Artist through the MusicKit api. The JSON response returned has a hasNextBatch: true value, but I am unsure how to fetch and display the next batch. Is this something that can be intelligently retrieved though some MusicKit functionality or does one have to perform another data request to fetch the next batch?
Posted Last updated
.
Post not yet marked as solved
0 Replies
473 Views
Currently in iOS 15 beta 2, you can the search suggestions to complete a search term, but is there a way that when the user select a suggestion, not only does it complete the term but also performs a .onSubmit? So that without having to hitting search on the keyboard, we can programmatically trigger a onSubmit?
Posted Last updated
.
Post marked as solved
1 Replies
696 Views
Hey everyone, I had a sample app I was working on with the first beta which had SharePlay/Group Activity working fine. Beta 2 seems to have broken it. It doesn't trigger any activity. I even tried deleting and reinstalling the app, but that doesn't seem to fix the issue either. Console error print:  Dropping activity as there is no active conversation Any ideas how to fix this issue?
Posted Last updated
.
Post marked as solved
3 Replies
1.1k Views
Hello, I am running my app written using SwiftUI on iOS 14 and the app crashes because of unexpectedly nil while unwrapping optional. This occurs when I try to share an image using its local URL in the Share Sheet. The puzzling part is that that it works perfectly on iOS 13. I am still new to development, so any help will be appreciated! Thanks in advance. struct ContentView: View {         @State private var imageURL: URL? @State private var isShareSheetPresented = false                  var body: some View {             ScrollView(.vertical) {                 VStack{                     Text("Test")             }             .navigationBarItems(trailing: Button(action: {                 writeImageToDisk()                 isShareSheetPresented.toggle()             }) {                 Image(systemName: "square.and.arrow.up")             }.sheet(isPresented: self.$isShareSheetPresented) {                 ShareSheet(photo: imageURL!)             })         }         func writeImageToDisk() {             imageURL = (UIApplication.shared.windows[0].rootViewController?.view!.getImage())! print(imageURL!)         } } // getImage is a function that returns an URL // imageURL is always getting printed successfully // Here is a sample of print(imageURL!) from console: file:///var/mobile/Containers/Data/Application/740E2665-8D68-4864-9E48-99E4E25D2985/Documents/Test%20Image.png // struct ShareSheet: UIViewControllerRepresentable {     let photo: URL                func makeUIViewController(context: Context) -> UIActivityViewController {         let activityItems: [Any] = [photo]                  let controller = UIActivityViewController(             activityItems: activityItems,             applicationActivities: nil)                  return controller     }            func updateUIViewController(_ vc: UIActivityViewController, context: Context) {     } }
Posted Last updated
.