Is there any plan to support edge-to-edge on iOS a...
# multiplatform
a
Is there any plan to support edge-to-edge on iOS and Android platforms under Compose Multiplatform? Or if there is any existing implementation/library, I'd like to know about it.
c
WindowInsets are already implemented in Multiplatform Compose. I believe that Compose is edge-to-edge by default unless you use the WindowInsets APIs, or maybe by customizing the usage of the WindowInsets
a
On JetPack Compose side (Android), you have to call
enableEdgeToEdge()
in your activity.onCreate() prior to calling
setContent { }
to make it work.
So it's not enabled by default.
c
But you also need to make changes to the Manifest for that activity. It can’t be configured directly in Compose, because those are attributes of the Window that holds the Compose UI, not necessarily of the UI drawing itself (which is what Compose does)
a
NoActionBar
theme is already setup on Manifest when you create your project through kmp website. So no issues on that side. I just want to know if iOS can be somehow enabled as well or not.
a
Copy code
var body: some View {
        ComposeView()
            .ignoresSafeArea()
    }
1
👍 1
a
@Alexander Zhirkevich Thank you. I had comment out
.keyboard
inside
.ignoresSafeArea(.keyboard)
and it worked.
275 Views