Help... me i did what is said

I am doing what it is saying, but it won’t work.

My code so far


class Fruits extends React.Component {
constructor(props) {
  super(props);
}
render() {
  return (
    <div>
      <h2>Fruits:</h2>
      <NonCitrus />
      <Citrus />
    </div>
  );
}
};

class TypesOfFood extends React.Component {
constructor(props) {
   super(props);
}
render() {
  return (
    <div>
      <Fruits />
      <Vegetables />
    </div>
  );
}
};

My browser information:

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

Challenge: Compose React Components

Link to the challenge:

I think it’s a bug… I even tried the solutions they gave you and it still didn’t work. You might want to create another topic under Freecodecamp support.

1 Like

Sure, let me write it under it.

The solution in the Guide was missing the original h1 element. So it appears, you were just using the same solution that was incorrect. I have now updated the solution in the Guide.

You can click Reset All Code to see what the original editor code starts off as and try to solve it again without looking at the solution.

1 Like