ref = {(nodo) => (this.avatareditor = node)}

this.nodeRef = React.createRef();

...

<Comp ref={this.nodeRef}/>
Different Donkey