Overview
TheStudyCard component displays your educational background, including degrees, qualifications, and certifications. It shows the title, score/grade, and completion year for each study.
Location
Source:src/components/sections/StudyCard.astro
Purpose
This component:- Displays your educational credentials
- Shows degree/qualification titles with scores
- Displays completion years
- Provides a clean, scannable format for academic achievements
Data Source
The component pulls data directly from thePROFILE object in src/content/profileData.ts:
Unlike Projects, Experiences, and Blog Posts, education data is stored in
profileData.ts rather than as a Content Collection. This is because educational entries are typically static and don’t need full markdown content pages.Usage
The component is used insrc/pages/index.astro:
Display Format
For each educational entry, the component shows:- Title - Degree or qualification name
- Score - Grade, GPA, or percentage (displayed as a badge)
- End Year - Year of completion
Layout
The component uses a flexible layout:- Each study entry is displayed in a full-width column
- Title and score are on the same line, justified between left and right
- Year is displayed below in a smaller font
- Entries are wrapped in a flex container with gap spacing
Adding Education Entries
To add a new degree or certification, edit thestudies array in src/content/profileData.ts:
Study Object Properties
title(required) - Full name of degree, certification, or qualificationlevel(optional) - Educational level (e.g., “Bachelor”, “Master”, “Secondary”)score(required) - Grade, GPA, percentage, or other achievement metricendYear(required) - Year of completion
The
level property is defined but not currently displayed in the component. You can add it to the template if you want to show it.Customization
Add Institutions
You can extend the data structure to include institution names:Add Date Ranges
To show start and end years:Add Links to Credentials
For certifications with verification links:Styling
- Score is displayed using the
Badgecomponent with “outline” variant - Year uses extra small font size for de-emphasis
- Full width layout ensures alignment
- Space-y-4 creates consistent vertical spacing
Why Not a Content Collection?
Education data is stored inprofileData.ts rather than as a Content Collection because:
- Simplicity - Educational entries typically don’t need full markdown content pages
- Quick Updates - Easier to edit a single TypeScript file
- Type Safety - Direct TypeScript types without schema conversion
- Performance - No need for file system queries
Related Components
- See the Card component for container styling