title: How to display object's keys and values in react component
body: <p>I have <code>ControlSection</code> component that one of it's props is <code>statistics</code> object prop. I want to display with <code>&lt;h2&gt;</code> all the key and values of the object. How can I do it?</p>
  
  <p>ControlSection:</p>
  
  <pre><code>const ControlSection = ({ statistics }) =&gt; {
      return (
          &lt;div className='gameStatistics'&gt;
              {
                  Object.keys(statistics).forEach(key =&gt; 
                      &lt;h2&gt;key: statistics[key]&lt;/h2&gt;
                  )
              }
          &lt;/div&gt;
      )
  }
  </code></pre>
  
  <p>Statistics example:</p>
  
  <pre><code>const statistics = {
      Score: score,
      Level: level,
      Best: bestScore,
  };
  </code></pre>