21.生命周期函数
执行顺序:creatde onLaunth onshow mounted (小程序用onLoad)
注意:如果页面需要传参,就必须用onLoad
uni.navigateBack与vueroute类似
返回上一页面或多级页面。可通过 getCurrentPages() 获取当前的页面栈,决定需要返回几层。
21.生命周期函数
执行顺序:creatde onLaunth onshow mounted (小程序用onLoad)
注意:如果页面需要传参,就必须用onLoad
uni.navigateBack与vueroute类似
返回上一页面或多级页面。可通过 getCurrentPages() 获取当前的页面栈,决定需要返回几层。