How do you prevent Compose from doing stuff when t...
# compose-ios
r
How do you prevent Compose from doing stuff when the keyboard opens? On Android I had to set
android:windowSoftInputMode="adjustNothing"
for things to stop moving and glitching under the status bar, but on iOS I don't know what to do. My view is already defined as
ComposeView().ignoresSafeArea()
(Which defaults to
.ignoresSafeArea(.all, .all)
)
Apparently replacing my ContentView from this:
Copy code
struct ContentView: View {

    var body: some View {
        ComposeView().ignoresSafeArea()
    }

}
to this:
Copy code
struct ContentView: View {

    var body: some View {
        GeometryReader { _ in
            ZStack {
                ComposeView().ignoresSafeArea()
            }.frame(
                width: UIScreen.main.bounds.width,
                height: UIScreen.main.bounds.height
            )
        }
    }

}
seems to work, but it's clearly a (ugly) hack
a
k
Copy code
ComposeUIViewController(
    configure = {
        onFocusBehavior = OnFocusBehavior.DoNothing
    }
)
thank you color 2