选择自己所爱的,然后爱自己所选择的!
子组件<template> <div> <span>myvalue: {{ myval...
直接在子组件中通过this.$parent.event来调用父组件的方法父组件<template> <div&g...
父组件调用子组件函数用法:子组件上定义ref="refName", 父组件的方法中用 this.$refs.refName.metho...
watch: { $route(to, from) { console.log('to=',to); ...
this.$router.push()1. 不带参数 this.$router.push('/home') this.$rout...