I need a help in Front End Development

Hi who can help me in the challenge 18 of react in the Front End Development

class CampSite extends React.Component{
  constructor(props) {
     const Camper = props => <p>{props.name}</p>;
     Camper.defaultProps = {
  name: "CamperBot"
Camper.propTypes = {
  name: PropTypes.string.isRequired
  render() {
    return (
        <Camper   />
export default CampSite;

he told me that i must do this to things

  • The CampSite component should render.

*The Camper component should render.
*The Camper component should contain a p element with only the text from the name prop.

I’ve edited your code for readability. When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.

You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.

See this post to find the backtick on your keyboard.
Note: Backticks (`) are not single quotes (').

Please post the link to the challenge you are working on. Thanks

React: Review Using Props with Stateless Functional Components | freeCodeCamp.org

Note: . is not `

But, you don’t need to put 3 ` around everything you type into the forum.

The 3 ` only go around blocks of code.

Did you read the code comment?

// Change code below this line

Move the code you put inside the CampSite component constructor, out of, and down to after the CampSite component, then remove the export as well.

I had change the code but but it still don’t work , any help please i had 10 days and i can’t find the solutions.

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