React Native KeyboardAvoidingView hides immediately

Viewed 220

I'm using the KeyboardAvoidingView to wrap a Flatlist that renders input, whenever I press on an input that is positioned when the keyboard is going to be on android, the keyboard hides immediately and also if I click one that is render above where the keyboard is going to be and scroll down, work perfect on ios.

Tried most of the things posted here, don't have any more clue.

<KeyboardAvoidingView
  behavior={Platform.OS === 'ios' ? 'padding' : 'height'}
  keyboardVerticalOffset={Platform.OS === 'ios' ? 90 : 100}
  style={{
    flex: 1,
  }}>
  {children}
</KeyboardAvoidingView>

Expected behavior

Actual behavior

Would appreciate any help

1 Answers

Found a solution for the issue, I've been using a Flatlist to render all the items in the list, switched to scroll view and works fine.

Related