Skip to content

Commit 9d737e9

Browse files
committed
fix: nav links work on all pages
1 parent 76cdda4 commit 9d737e9

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

components/navbar.vue

+2-1
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ const scrollToSection = async (el) => {
4444
section: id
4545
}
4646
})
47-
section.scrollIntoView({ behavior: 'smooth' })
47+
const section = document.getElementById(id)
48+
section.scrollIntoView({ behavior: "smooth" })
4849
}
4950
</script>
5051

0 commit comments

Comments
 (0)