Menu
Coddy logo textTech

Step 2: Card with Props

Part of the Fundamentals section of Coddy's React journey — lesson 40 of 42.

challenge icon

Challenge

Easy

Make the card reusable.

  1. Define ProfileCard receiving name and bio props, rendering the same structure as step 1 (card div, id="profile-name", id="profile-bio") with the prop values.
  2. In App, render one ProfileCard with name Grace Hopper and bio Invented the compiler.

Try it yourself

<!DOCTYPE html>
<html>
    <head>
        <link rel="stylesheet" href="styles.css" />
    </head>
    <body>
        <div id="root"></div>
        <script type="module" src="main.jsx"></script>
    </body>
</html>

All lessons in Fundamentals