understanding <a> in nextjs

Hello I am a little confused about how links work in nextjs I am using the <a> tag. In the first image I use the <a> tag an get no errors but in the second image I get an error. any insight on why this is the case?
9 Replies
Ani
AniOP2y ago
image 1
Ani
AniOP2y ago
Ani
AniOP2y ago
image 2
Ani
AniOP2y ago
cornflour
cornflour2y ago
you are having a typo on the second one herf instead of href
Ani
AniOP2y ago
LMAO thats what happens when you havent slept in 2 days
Neto
Neto2y ago
also if you can, use next <Link> component will avoid a full page refresh
Ani
AniOP2y ago
ah alr sorry for my idiocy again havent slept in 2 days so
Neto
Neto2y ago
its all good
Want results from more Discord servers?
Add your server