--- interface Props { name: string; linkUri: string; } const { name, linkUri } = Astro.props; function extractInitials(name: string) { // Split the name into words const words = name.split(" "); // Iterate over the words and extract the initials const initials = words.map((word) => word.charAt(0).toUpperCase()).join(""); return initials; } const initials = extractInitials(name); const linkLabel = linkUri.replace(/^https?:\/\//, ""); ---
  • {initials}

    {name}

    {linkLabel}