Render a Class Component to the DOM---not working!

Tell us what’s happening:

No progress

Your code so far



class TypesOfFood extends React.Components {
  constructor(props) {
    super(props);
  }
  render() {
    return (
      <div>
        <h1>Types of Food:</h1>
        {/* change code below this line */}
        <Fruits />
        <Vegetables />
        {/* change code above this line */}
      </div>
    );
  }
};

// change code below this line
ReactDOM.render(<TypesOfFood />, document.getElementById("challenge-node"))

Your browser information:

User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/65.0.3325.162 Safari/537.36.

Link to the challenge:

The error:

Super expression must either be null or a function, not undefined

is telling you there is something wrong with super a built in method of your class. The problem is here:

class TypesOfFood extends React.Components {

It’s not “Components”, it’s “Component”.

Thanks a lot man, I appreciate that!