# wx.onKeyboardHeightChange(function callback)
Start from base library version 2.7.0. Please remaining backward compatible.
with Promise style call: Not supported
Mini Program plugin: Not supported
Monitor keyboard height changes
# parameter
# function callback
# parameter
# Object res
attribute | type | Introductions |
---|---|---|
height | number | Keyboard height |
# sample code
wx.onKeyboardHeightChange(res => {
console.log(res.height)
})