S
Seoffix.com
Sign In Get Pro Membership

React & Modern Frontend

React Components

Intermediate React 30 XP

React Components

A component is a function that returns markup. Props arrive as its first argument.

Example

function Badge({ text }) {
  return <span>{text}</span>;
}

Your task

Write a Card component that renders its title prop inside a div.

Hints

  1. Return JSX
  2. Destructure title from props

Check your understanding

Answer every question to pass.
1. What do props carry into a component?

Your answer

This lesson is checked against the lesson rules. Your code is never run on our servers.

AI Code Explainer & Translator

Runs without any outside service.
 
Mark Complete & Earn XP
Earn 30 XP after you pass the quiz. Finish every lesson in the track to earn its certificate.
Sign in to earn XP

React & Modern Frontend

Lessons in this track
Questions about this lesson? Ask the Coding & Web Dev squad. Discuss in Community