bl.onEmbeddedMiniProgramHeightChange
小程序插件:不支持
功能描述
监听半屏小程序可视高度变化事件
参数
function listener
半屏小程序可视高度变化事件的监听函数
参数
Object res
| 属性 | 类型 | 说明 |
|---|---|---|
| height | number | 可视高度 |
| initialHeight | number | 半屏小程序初始高度 |
示例代码
const func = function (res) {
console.log(res.height)
console.log(res.initialHeight)
}
bl.onEmbeddedMiniProgramHeightChange(func)
// 取消监听
bl.offEmbeddedMiniProgramHeightChange(func)