父组件
<button onClick={
this.reset}>重置</button>
<Son ref='son' onRef={
this.onRef}></Son>
reset=()=>{
this.son.clickReset()
}
onRef=(ref)=>{
this.son=ref
}
子组件
componentDidMount=()=>{
this.props.onRef(this)
}
clickReset=()=>{
alert("重置")
}