When I click a .nav-link button in the nav element, I am taken to the corresponding section of the landing page.'

Hello,
I don’t understand why i get stuck on storie 5 of Product Landing Page project…

The links work well however…

An idee ?

Thank you

there is always an explanation of what’s going wrong below the failed user story:

Each .nav-link element should have an href attribute

can you think what’s going wrong knowing this?

It is the case ?

<nav id="nav-bar">
        <ul>
          <li class="nav-link"><a href="#feat">Features</a></li>
          <li class="nav-link"><a href="#how">HowItWorks</a></li>
          <li class="nav-link"><a href="#price">Princing</a></li>
        </ul>
      </nav>

can a element have a href attribute?

Thank you to help me
I think no … for me it’s the right syntax…

i checked on https://validator.w3.org/ and the is no errors…

so if the elements with the .nav-link class need to have a href attribute, what kind of elements should they be instead?

tag <a> need an herf attribut, that what have done…

Ok, get it !

<li ><a class="nav-link" href="#feat">Features</a></li>

Thank’s for your help :wink: