React - Compose React Components

I don’t know what did i do wrong? Please help

class Fruits extends React.Component {
  constructor(props) {
    super(props);
  }
  render() {
    return (
      <div>
        <h2>Fruits:</h2>
 { /* change code below this line */ }        
        <NonCitrus />
        <Cirtrus />
 { /* change code below this line */ }       
      </div>
    );
  }
};

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

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36

Challenge: React - Compose React Components

Link to the challenge:

Hello, You left the curly brackets around the comments, All you need to do is remove them.

1 Like

The component name is Citrus not Cirtrus

1 Like

Thank you so much :slight_smile:

i see it lol Thank you :slight_smile:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.