https://kotlinlang.org logo
#multiplatform
Title
# multiplatform
j

james

04/13/2021, 4:37 PM
Anyone have experience with using Mapbox with Kotlin Multiplatform?
d

Derek Ellis

04/13/2021, 4:38 PM
Yes, I have a project that's more or less centered around it
j

james

04/13/2021, 4:39 PM
Is this project public, i'm curious to hear if you have had any challenges with using mapbox with KMM and how you went about dealing with view logic in both iOS & Android respectively.
d

Derek Ellis

04/13/2021, 4:40 PM
This was my proof of concept for having data sources come from common code: https://github.com/dellisd/mmapp The full project is here, but it's a bit messy: https://github.com/cuhacking/atlas There's also this library, if you haven't seen it already: https://github.com/icerockdev/moko-maps
j

james

04/13/2021, 4:42 PM
I had not seen that, i'll look through both of those. I'm particularly interested in using Mapbox route navigation in Kotlin Multiplatform.
m

mkrussel

04/13/2021, 4:46 PM
One thing to know is that the new Mapbox v10 (in beta) does not work great with KMP. It is rewritten in Swift with very little code exposed to Objective-C. Since KMP only interops with Objective-C, I've had to build a wrapper around the functionality in Mapbox that I want. The stuff I've been doing is not public.
👍 2
d

Derek Ellis

04/13/2021, 4:47 PM
Swift interop is supposed to be in the works, but it's still a longer term goal (as of the last roadmap update)
c

Colton Idle

04/14/2021, 12:52 AM
KMP interops with objc? Oh. That does not sound fun. 😄
454 Views