当前位置:网站首页>Uniapp gets the instance of the previous page

Uniapp gets the instance of the previous page

2022-06-12 01:08:00 Wang Li

The following is the stack list of all pages

let pages = getCurrentPages(); //  Stack of all pages 
let prevPage = pages[pages.length - 2]; //  The example on the previous page 
prevPage.$vm----> This is the example on the previous page 

 For example, to operate on the previous page data Defined name
prevPage.$vm.name = ' assignment '
原网站

版权声明
本文为[Wang Li]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/03/202203011415186519.html