MortyComposeKMM
MortyComposeKMM copied to clipboard
snapshotList issue on ForEach
Type '((Any) throws -> Bool) throws -> Any?' cannot conform to 'RandomAccessCollection'
Only concrete types such as structs, enums and classes can conform to protocols
Required by generic struct 'ForEach' where 'Data' = '((Any) throws -> Bool) throws -> Any?'
Thanks for the report. I just built/ran iOS client here and seemed to work. Are there any other factors you know about that might effect issue? I'm using Xcode 15.4 still here fwiw.
I use xcode 16 and minimum ios version is 15.6
how can I solve the issue. I do need pagination implementation on ios side of my kmp project
hmm, I've tried with Xcode 16 and it seems to work
The Kotlin 2.0.21-RC release is supposed to have better Xcode 16 support....might be worth trying with that there
hmm, actually I use 'Kotlin 2.0.0'
Kotlin version did not solve the issue, after that I casted MutableStateFlow<ItemSnapshotList<T>> to MutableStateFlow<List<T>> where RandomAccessCollection supports, the casting cannot solve it too, After checking type of declared variable in swiftUI (let snapshotList = self.viewModel.booksSnapshotList) I saw it gives ( let snapshotList: [Any] ) in both cases too. How dou you think is the issue can be on that