vue监控属性变化(分页获取数据)

watch: {
	// 监视pagination属性的变化
	pagination: { 
		// deep为true,会监视pagination的属性及属性中的对象属性变化
		deep: true, 
		handler() {
      		// 变化后的回调函数,这里我们再次调用getDataFromServer即可
      		this.getDataFromServer();
    	}
  	}
}
全部评论

相关推荐

北漂的牛马人:211佬,包进的,可能是系统问题
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务