關(guān)于跳轉(zhuǎn)頁(yè)面及數(shù)據(jù)的傳遞
<navigator open-type="navigate" url="tab1?id=11111">默認(rèn)跳轉(zhuǎn),跳轉(zhuǎn)相應(yīng)頁(yè)面虎忌,可返回</navigator>
<navigator open-type="redirect" url="tab3">關(guān)閉當(dāng)前頁(yè)面布卡,跳轉(zhuǎn)到相應(yīng)頁(yè)面</navigator>
<!-- <navigator open-type="navigateBack" >返回上一頁(yè)</navigator> -->
<navigator open-type="reLaunch" url="tab3">跳轉(zhuǎn)到相應(yīng)頁(yè)面躯护,并關(guān)閉所有頁(yè)面</navigator>
<navigator open-type="switchTab" url="tab2">只能跳轉(zhuǎn)到tab頁(yè)面</navigator>
1.navigate :默認(rèn)跳轉(zhuǎn),跳轉(zhuǎn)相應(yīng)頁(yè)面独撇,可返回
redirect:關(guān)閉當(dāng)前頁(yè)面混狠,跳轉(zhuǎn)到相應(yīng)頁(yè)面
reLaunch:跳轉(zhuǎn)到相應(yīng)頁(yè)面岸霹,并關(guān)閉所有頁(yè)面
navigateBack:當(dāng)有上一頁(yè)的時(shí)候,返回上一頁(yè)
switchTab:只能跳轉(zhuǎn)到tab頁(yè)面
2.跳轉(zhuǎn)到話将饺。是在url上加問(wèn)號(hào):例如
<navigator open-type="navigate" url="tab1?id=11111"></navigator>
然后在跳轉(zhuǎn)到的頁(yè)面贡避,用props接收 例如
<script>
export default {
props:['id']
}
</script>