title: Const vs Class Functions is React Native
body: <p>I have been watching a few tutorials recently on RN and I have noticed a few of them do not use class when creating a component, instead, they are using const. The code below shows the homescreen for the app for that particular tutorial. My question is: is there a reason they are doing it this way and not using class? Also, does it matter? Is there a particular reason you would use const instead of class?</p>
  
  <pre><code>const HomeScreen = ({ navigation }) =&gt; {
      return (
        &lt;View&gt;
          &lt;Text style={styles.textStyle}&gt;This is the Home Screen&lt;/Text&gt;
          &lt;Button title="Go to Components Demo"
            onPress={() =&gt; navigation.navigate('Components')}
          /&gt;
          &lt;Button title="Go to list demo"
            onPress={() =&gt; navigation.navigate('List')}
          /&gt;
          &lt;Button title="Go to Image Screen"
          onPress={() =&gt; navigation.navigate('Image')}
          &gt;&lt;/Button&gt;
          &lt;Button title="Go to Counter"
          onPress={() =&gt; navigation.navigate('Counter')}
          &gt;&lt;/Button&gt;
          &lt;Button title="Colors"
          onPress={() =&gt; navigation.navigate('Color')}
          &gt;&lt;/Button&gt;
          &lt;Button title="Squares"
          onPress={() =&gt; navigation.navigate('Square')}
          &gt;&lt;/Button&gt;
        &lt;/View&gt;
      );
    };
  
  
  const styles = StyleSheet.create({
    textStyle: {
      fontSize: 30,
      textAlign: "center"
    },
  });
  
  export default HomeScreen;
  </code></pre>