bl.onAfterPageUnload
功能描述
监听路由事件引起现有页面实例销毁时,页面实例销毁后的事件监听,详见 页面路由监听。
参数
function listener
路由事件的监听函数
参数
Object res
| 属性 | 类型 | 说明 |
|---|---|---|
| path | string | 页面路径 |
| routeEventId | string | 路由事件 id |
示例代码
const func = function (res) {
console.log(res)
}
bl.onAfterPageUnload(func)
// 取消监听
bl.offAfterPageUnload(func)