引入:https://q.cnblogs.com/q/88214/
解决方法:
添加路由监听,路由改变时执行监听方法
methods:{ fetchData(){ console.log('路由发送变化doing...'); } }, created() { var self = this; self.fetchData(); }, watch:{ '$route':'fetchData' },
引入:https://q.cnblogs.com/q/88214/
解决方法:
添加路由监听,路由改变时执行监听方法
methods:{ fetchData(){ console.log('路由发送变化doing...'); } }, created() { var self = this; self.fetchData(); }, watch:{ '$route':'fetchData' },