I have to run Child component method in Parent Component. It's not official but I need to run this for complicated code... I try to use `refs` but it is not working in Parent Component. The error below occurs.

> 
> Cannot read property 'renderSetup' of undefined
> 
> 
> 

Parent Component:

```
class Parent extends Component {
  constructor(props) {
    super(props);
    this._renderSetup = this._renderSetup.bind(this);
  }

  componentDidMount() {
    this._renderSetup();
  }

  _renderSetup() {
    this.refs.Child.renderSetup();
  }

  render() {
    return (
      <Child ref={Child} />
    )
  }

```

Child Component

```
class Child extends Component {
  constructor(props) {
    super(props);
    this.renderSetup = this.renderSetup.bind(this);
  }

  renderSetup = () => {
     // complicated code
  }

```