onHide() {
const pages = getCurrentPages();
const currentPage = pages[pages.length - 1];
console.log(currentPage.route)
},

- 发布:2022-04-14 11:27
- 更新:2022-04-14 11:27
- 阅读:417
产品分类: uniapp/H5
PC开发环境操作系统: Windows
PC开发环境操作系统版本号: 2017.8
HBuilderX类型: 正式
HBuilderX版本号: 3.4.5
浏览器平台: Chrome
浏览器版本: 版本 96.0.4664.110(正式版本) (64 位)
项目创建方式: HBuilderX
操作步骤:
预期结果:
获取到当前页面路径
获取到当前页面路径
实际结果:
获取的是首页路径
获取的是首页路径
bug描述:
onHide h5的onHide获取当前页面路径一直显示首页,在app上面正常
const pages = getCurrentPages();
const currentPage = pages[pages.length - 1];
console.log(currentPage.route)
0 个回复