我有一个 v-text-field 搜索框。按回车键,搜索框会调用search(keyword) 在搜索中(关键字):
this.$router.push({path:'/search', query:{keyword:keyword}});
我第一次搜索像vacuum
这样的关键字它有效,页面可以呈现搜索结果页面,
然后我搜索另一个关键字,如 air
,它不会重新呈现关键字 air
的搜索结果页面。
现在我使用 this.$router.go(0)
重新加载页面:
this.$router.push({path:'/search', query:{keyword:keyword}});
this.$router.go(0)
它可以工作。但是我的 web api 服务器会显示 tcp-write: error writing system error:An established connection was aborted by the software in your host machine.; errid=10053
。
所以,我想知道当路径相同但查询或参数不同时,还有哪些其他方法可以重新加载页面。