title: Need to dynamically add items into a drawer menu in React Native
body: <p>I need to have some items dynamically in my app's drawer after some categories get fetched from a json file (<a href="https://www.rallyssimo.it/wp-json/wp/v2/categories" rel="nofollow noreferrer">https://www.rallyssimo.it/wp-json/wp/v2/categories</a>) </p>
  
  <p>json example (I need that information)</p>
  
  <pre><code>[
    {
      "id": 44,
      .
      .
      "name": "ALTRI RALLY",
      .
      .
    },
  </code></pre>
  
  <p>Tis is the drawer:</p>
  
  <pre><code>const CustomDrawerComponent = (props) =&gt; (
    &lt;SafeAreaView style={{flex:1}}&gt;
      &lt;View style={{height:80, backgroundColor: 'white', alignItems: 'center', justifyContent: 'center'}}&gt;
        &lt;Image
          source={{uri: 'https://www.rallyssimo.it/wp-content/uploads/2016/08/rallyssimo-logo.png'}}
          style={{ height: 60, width: 180}}
        /&gt;
      &lt;/View&gt;
      &lt;ScrollView&gt;
        &lt;DrawerItems {...props} /&gt;
      &lt;/ScrollView&gt;
    &lt;/SafeAreaView&gt;
  )
  </code></pre>
  
  <pre><code>const AppNavigator = createDrawerNavigator(
    {
      Home: DashboardStackNavigator,
    },
    {
      contentComponent: CustomDrawerComponent
    }
  );
  
  const AppContainer = createAppContainer(AppNavigator);
  
  
  //Main class
  export default class App extends React.Component {
    render() {
      return &lt;AppContainer /&gt;;
    }
  }
  </code></pre>
  
  <p>How can I put the items (I'm going to get from the JSON) in the drawer?</p>