Accessing method of another component on React-Native
<p>I have 2 components <code>A</code> and <code>B</code> as below,</p>

<pre><code>class A extends Component {

  testMethodA() {

  }

  render() {
      return (
          &lt;View style={[styles.scene, {backgroundColor: 'red'}]}&gt;
              &lt;TouchableHighlight onPress={this.onPress}&gt;
                  &lt;Text&gt;Welcome. Press here!&lt;/Text&gt;
              &lt;/TouchableHighlight&gt;
          &lt;/View&gt;
      );
  }
}


class B extends Component {

  testMethodB() {

  }

  render() {
      return (
          &lt;View style={[styles.scene, {backgroundColor: 'red'}]}&gt;
              &lt;TouchableHighlight onPress={this.onPress}&gt;
                  &lt;Text&gt;Welcome. Press here!&lt;/Text&gt;
              &lt;/TouchableHighlight&gt;
          &lt;/View&gt;
      );
  }
}
</code></pre>

<p>How can I access <code>testMethodA</code> from <code>B</code> and <code>testMethodB</code> from <code>A</code>?</p>