title: Getting this warning "Functions are not valid as a React child"
body: <p>I am trying to render a list of movies from an array object in an html table format. I am getting this warning:</p>
  
  <p>Warning: Functions are not valid as a React child. This may happen if you return a Component instead of  from render. Or maybe you meant to call this function rather than return it.</p>
  
  <pre><code>import React from 'react';
  import {movies} from '../services/fakeMovieService';
  
  class Movies extends React.Component {
  constructor(props) {
      super(props);
  
      this.tableFormat = this.tableFormat.bind(this);
  }
  
      tableFormat() {
          movies.map((movie) =&gt; {
              return (
                  &lt;tr&gt;
                      &lt;td key={movie._id}&gt;{movie.title}&lt;/td&gt;
                  &lt;/tr&gt;
              );
          });
      }
  
  
      render() {
  
          return (
              &lt;table className="table"&gt;
                  &lt;thead&gt;
                      &lt;tr&gt;
                          &lt;th&gt;Title&lt;/th&gt;
                          &lt;th&gt;Genre&lt;/th&gt;
                          &lt;th&gt;Stock&lt;/th&gt;
                          &lt;th&gt;Rate&lt;/th&gt;
                      &lt;/tr&gt;
                  &lt;/thead&gt;
                  &lt;tbody&gt;
                      {this.tableFormat()}
                  &lt;/tbody&gt;
              &lt;/table&gt;
  
          );
      }
  }
  
  export default Movies;
  </code></pre>