diff --git a/components/GC.vue b/components/GC.vue
index af579ef..d1aa47a 100644
--- a/components/GC.vue
+++ b/components/GC.vue
@@ -73,7 +73,7 @@ function filterLastByMonth(contributions: Day[], month: number) {
return contributions.filter(day => range.includes(day.date))
}
-onMounted(async () => {
+watch(() => props.username, async () => {
loading.value = true
const data = await fetchContribution(props.username)
@@ -95,11 +95,11 @@ onMounted(async () => {
loading.value = false
}
-})
+}, { immediate: true })
-async function fetchContribution(name: string, _year = 'last') {
+async function fetchContribution(name: string, year = 'last') {
const { data } = await useFetch
+ Loading ···
+