| --- | |
| import HtmlFragment from "./HtmlFragment.astro"; | |
| interface Props { | |
| title: string; | |
| description?: string; | |
| } | |
| const { title, description } = Astro.props as Props; | |
| --- | |
| <section class="hero"> | |
| <h1 class="hero-title" set:html={title}></h1> | |
| <div class="hero-banner"> | |
| <HtmlFragment src="banner.html" /> | |
| {description && <p class="hero-desc">{description}</p>} | |
| </div> | |
| </section> | |