How do i make nav bar show at which section i am?

Im curious how to make my nav bar when i click on i.e. About it scroll’s to that section of the site. I dont know how is that called i know on bootstrap it has plugin called Scrollspy, but i used CSS Grid for my sections (excluding header and navbar).

Here’s my codepen if needed:

For example your nav has this link to the About section:
<a href="#">About</a>
And at the About section… which is the about section? Let’s say it is that of class section-b.
First you need to use the id tag, like:
<section id="section-b">...</section>
And then at the link on the nav:
<a href="#section-b">About</a>
That’s all.

There’s this lesson at you can check also.

1 Like

Ok but what do i type in for Home?

EDIT: Nvm i did it. Thanks for your answer.

You’re welcome. I’m glad to help!