completed exercise 1.2

This commit is contained in:
counterweight 2025-05-18 19:50:11 +02:00
parent c118246961
commit 3bcd98dd10
Signed by: counterweight
GPG key ID: 883EDBAA726BD96C

View file

@ -2,11 +2,16 @@ const Header = (props) => {
return <h1>{props.course}</h1> return <h1>{props.course}</h1>
} }
const Part = (props) => {
return <p>{props.partName} {props.exerciseCount}</p>
}
const Content = (props) => { const Content = (props) => {
return ( return (
<> <>
{props.sections.map((section) => { {props.sections.map((section) => {
return <p>{section.part} {section.exerciseCount}</p> return <Part partName={section.part} exerciseCount={section.exerciseCount}/>
})} })}
</> </>
) )