Files
Basalt2/node_modules/shiki/samples/jsx.sample
Robert Jelic 31787b0e9b Fix
2025-02-16 18:04:24 +01:00

31 lines
582 B
Plaintext

function Item({ name, isPacked }) {
if (isPacked) {
return null;
}
return <li className="item">{name}</li>;
}
export default function PackingList() {
return (
<section>
<h1>Sally Ride's Packing List</h1>
<ul>
<Item
isPacked={true}
name="Space suit"
/>
<Item
isPacked={true}
name="Helmet with a golden leaf"
/>
<Item
isPacked={false}
name="Photo of Tam"
/>
</ul>
</section>
);
}
// From https://react.dev/learn/conditional-rendering