- 使用
this.$router.go(0)
可以刷新当前页面; - 使用
this.$router.replace()
可以替换当前页面; - 使用
this.$router.push()
可以跳转到新页面; - 使用
this.$router.push({path: '/xxx', query: {a: 1}})
可以跳转到新页面,并传递参数; - 使用
this.$router.push({name: 'xxx', params: {a: 1}})
可以跳转到新页面,并传递参数; - 使用
this.$router.push({path: '/xxx', query: {a: 1}, replace: true})
可以替换当前页面,并传递参数; - 使用
this.$router.push({name: 'xxx', params: {a: 1}, replace: true})
可以替换当前页面,并传递参数; - 使用
this.$router.go(-1)
可以返回上一页; - 使用
this.$router.go(1)
可以前进一页; - 使用
this.$router.go(-2)
可以返回上两页; - 使用
this.$router.go(2)
可以前进两页; - 使用
this.$router.go(-n)
可以返回上n页; - 使用
this.$router.go(n)
可以前进n页;
vue跳转后怎么刷新跳转后的页面
原创
©著作权归作者所有:来自51CTO博客作者米女巫的原创作品,请联系作者获取转载授权,否则将追究法律责任
下一篇:鼠标光标指针样式 CSS
提问和评论都可以,用心的回复会被更多人看到
评论
发布评论
相关文章