异步之后的回调this.$nextTick() this.$nextTick()将回调延迟到下次 DOM 更新循环之后执行 案例展示 <script> export default { created() { console.log(this.$refs.allcity) //输出:undefined this.$nextTick(() => { console.log(this.$refs.allcity) //输出:VueComponent内容 }) }, } </script>