title: refreshControl gives "undefined is not a function..." in react-native app
body: <p>I'm trying to add refresh functionality in my ScrollView, but when trying to refresh I get this error:</p>
  
  <pre><code>undefined is not a function (evaluating '(0,_reactNative.fetchData)()')
  </code></pre>
  
  <p>I have followed the example <a href="https://facebook.github.io/react-native/docs/refreshcontrol.html" rel="nofollow noreferrer">in the documentation</a></p>
  
  <p>Here is my code</p>
  
  <pre><code>class Schedule extends Component {
  
   constructor(props) {
      super(props);
      this.state = {
        refreshing: false
      };
    }
  
    _onRefresh() {
      this.setState({refreshing: true});
      fetchData().then(() =&gt; {
        this.setState({refreshing: false});
      });
    }
   render() {
    return (
  &lt;View&gt;
   &lt;ScrollView
        style={{backgroundColor: "white"}} scrollEnabled={true} horizontal={false}
        refreshControl={
          &lt;RefreshControl
            refreshing={this.state.refreshing}
            onRefresh={this._onRefresh.bind(this)}
          /&gt;
        }
      &gt;
     &lt;View&gt;
      //...Content I'm trying to refresh
     &lt;/View&gt;
  
  &lt;/View&gt;
  &lt;/ScrollView&gt;
    )
   }
  }
  </code></pre>
  
  <p>I can't imagine there being anything wrong with the code itself, as it's taken straight from the example. There shouldn't be any problems with the imports either</p>
  
  <pre><code>import {View, ScrollView, RefreshControl, fetchData } from 'react-native';
  </code></pre>