refactored

This commit is contained in:
Pablo Martin 2025-05-20 16:40:29 +02:00
parent 1d48e78d7f
commit 3864c11b9b
4 changed files with 35 additions and 23 deletions

View file

@ -0,0 +1,15 @@
import Part from "./Part";
const Content = (props) => {
return (
<>
{props.sections.map((section) => {
return (
<Part key={section.part} partName={section.part} exerciseCount={section.exerciseCount} />
);
})}
</>
);
};
export default Content;

View file

@ -0,0 +1,5 @@
const Header = (props) => {
return <h1>{props.course}</h1>;
};
export default Header;

View file

@ -0,0 +1,9 @@
const Part = (props) => {
return (
<p>
{props.partName} {props.exerciseCount}
</p>
);
};
export default Part;