Created
June 26, 2024 15:17
-
-
Save adhithiravi/5dfdbc0d00d40ba07bc288fc73eb77fb to your computer and use it in GitHub Desktop.
Speaker information
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export default async function Speaker({ | |
params: { slug }, | |
}: { | |
params: { slug: string }; | |
}) { | |
const speakerInfo = await getSpeakerInfo(slug); | |
const { name, bio, id, sessions }: SpeakerWithSessions = speakerInfo; | |
return ( | |
<section key={id} className={styles.infoContainer}> | |
<h3 className={styles.titleText}>{name}</h3> | |
<h5 className={styles.descText}>About: {bio}</h5> | |
{sessions && | |
sessions.map(({ name, id }: SpeakerSummary) => ( | |
<section key={id}> | |
<h5 className={styles.descText}>Session: {name}</h5> | |
</section> | |
))} | |
</section> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment