Hello Everybody. My Compose Multiplatform applicat...
# compose
r
Hello Everybody. My Compose Multiplatform application uses MapBox for Android and iOS to display the map. I want to show views on the map, so I am using ViewAnnotation within iOS that requires an UIView. The marker that I would like to show is something I would like to have as Composable, let's call it MapMarker. I could have
ComposeUIViewController(configure = { opaque = false }) { MapMarker(marker = ..) }
but this would result in the annotation taking full screen, when using
viewController.view
and adding that as ViewAnnotation. Using
widthAnchor/heightAnchor
on the view and limiting the view to a size I set within my composable works, but is there another way to make the ViewController not use full height, but wrap? Also an iOS colleague looked at me weirdly, because I have like 40 view annotations on the map and having multiple ViewController is bad. Is there a way to encapsulate a single composable component within UiView that shouts "performance"? Thanks!