aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlam Guardin <54455101+alamguardin@users.noreply.github.com>2024-08-24 20:07:00 -0500
committerGitHub <noreply@github.com>2024-08-24 20:07:00 -0500
commit4a89ff454fdce3f6be57609c2429bc8f622626ef (patch)
treed96373991a9d36d1410bba28c7e905e4e754bc8a
parent357b4e5faf660fa4c71ff5f3339ddb02b2030101 (diff)
parent8cdb92a727037ca4358f5d8700d4585eb8741a4a (diff)
Merge pull request #1 from clementvial/feature/dynamic-user-data
Refactor Profile component to load user data from JSON file
-rw-r--r--src/components/Profile.astro5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/components/Profile.astro b/src/components/Profile.astro
index d174a9c..ba51fb6 100644
--- a/src/components/Profile.astro
+++ b/src/components/Profile.astro
@@ -1,5 +1,6 @@
---
import UserProfileImage from '../assets/user-profile-image.png'
+import dataList from '../data/user.json';
---
<header class="profile">
@@ -9,8 +10,8 @@ import UserProfileImage from '../assets/user-profile-image.png'
</figure>
</div>
<div class="profile-data">
- <h1 class="profile-name">Kelly Bowlin</h1>
- <p class="profile-profession">Web Designer</p>
+ <h1 class="profile-name">{dataList.name}</h1>
+ <p class="profile-profession">{dataList.profession}</p>
</div>
</header>
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage