title: React native function as prop in flatlist item
body: <p>Hello I have a problem with calling a function passed as prop at the child component. Im trying to replicate my code with only the relevant lines of code:</p>
  
  <pre><code>class Parent extends Component {
    constructor(props) {
      super(props)
      this.press = this.press.bind(this)
    }
    press(param) {
      console.log(param)
    }
    renderItem = ({item}) =&gt; (
      &lt;Child item={item} press={this.press} /&gt;
    )
  
    render() {
      return (
        &lt;FlatList renderItem={this.renderItem} /&gt;
      )
    }
  }
  
  class Child extends PureComponent {
  
    handlePress(param) {
      // do some stuff
      // call parent function
      this.props.press(param)
    }
    render() {
      const { id } = item
      return &lt;Button onPress={() =&gt; this.handlePress(id)} /&gt;
    }
  }
  </code></pre>
  
  <p>At the moment when pressing the button nothing happens, I got this already working with something like this:</p>
  
  <pre><code>&lt;Child press={(param) =&gt; this.press(param)} /&gt;
  </code></pre>
  
  <p>however this causes performance issues.</p>
  
  <p>How can I make this work ?</p>