链接
href= url?name=’’>>>"
取参
var data = window.location.href.split("?")[1].split("=")[1]
本页面跳转到指定位置
id = aaa
window.location.hash = ‘#aaa’
路由跳转到组件顶部
router: {
scrollBehavior: function (to, from, savedPosition) {
console.log(‘1223’)
return {
x: 0,
y: 0
}
}
},