uni-app $refs的基本用法
<template>
<view class="container">
<child :showModal="showModal" ref="vref"></child>
<button @tap="refMethods" type="primary" >点击</button>
</view>
</template>
<script>
import child from "../../components/"
export default {
components: {
child
},
data() {
return {
showModal: " parent say",
parentValue: '',
syncDate: ' p syncDate'
};
},
methods: {
refMethods() {
var child = this.$;
();
}
}
}
</script>
<style>
</style>