title: FlatList onEndReached called On Load (React Native)
body: <p>When I use <code>onEndReached</code> function in <code>FlatList</code>, it gets called automatically.</p>
  
  <p>Below is the link of this issue.</p>
  
  <p><a href="https://github.com/facebook/react-native/issues/16067" rel="nofollow noreferrer">Link</a></p>
  
  <p>Is there a solution available for it or any alternative in iOS?</p>
  
  <p><strong>Edited:</strong> </p>
  
  <p>Below is the code I tried but this doesn't seems to work.</p>
  
  <pre><code>constructor(props){
          super(props);
          this.state = {
              flatListReady:false
          }
      }
  
      loadMore(){
          if(!this.state.flatListReady){
              return null;
          }
          else{
              alert("End Reached")
          }
      }
  
      _scrolled(){
          this.setState({flatListReady:true});
      }
  
      render() {
          return (
              &lt;Layout style={{ flex: 1 }}&gt;
  
                  &lt;FlatList
                      data={listData}
                      renderItem={({item}) =&gt; this._renderItem(item)}
                      keyExtractor={(item, index) =&gt; item.key}
                      onEndReached={() =&gt; this.loadMore()}
                      onEndReachedThreshold={0.5}
                      onScroll={() =&gt; this._scrolled()}
                  /&gt;
  
              &lt;/Layout&gt;
  </code></pre>