How to get a height of a Keyboard in React-Native?

后端 未结 4 1074
一整个雨季
一整个雨季 2020-12-08 03:49

I am using React-Navigation in my app and the app consists of StackNavigator with multiple screens, some screens of which have TextInput with autoFocus={true}

4条回答
  •  无人及你
    2020-12-08 04:45

    Just would like to add to the above answers, that using keyboardWillShow and keyboardWillHide rather than keyboardDidShow and keyboardDidHide will look much better. It just runs sooner and hence, looks smoother.

提交回复
热议问题