--- // Import PrimaryCTA component import PrimaryCTA from '@components/ui/buttons/PrimaryCTA.astro'; // Destructure the props passed to the Astro component const { title, subTitle, btnExists, btnTitle, btnURL } = Astro.props; // Define TypeScript interface for props interface Props { title: string; subTitle: string; btnExists?: boolean; btnTitle?: string; btnURL?: string; } --- {/* Root section of the component */}
{/* Section title */}

{title}

{/* Section subtitle */}

{subTitle}

{ /* Conditional rendering of PrimaryCTA component if 'btnExists' property is truthy */ } { btnExists ? (
) : null }