Technical Documentation page menu layout

Hello fellow coders!

I have a question about a small detail when designing navigation menus. Rather that having the link be the text itself, I am wondering how to make the whole box that the text is situated within be the link. I hope that makes sense.

The example page for the project is a good example of this.
https://codepen.io/freeCodeCamp/full/NdrKKL

I like how the user doesn’t have to click on the actual text to be directed to the corresponding part of the page. They can just click anywhere in the box. Does anyone know how to do this?

Use the dev tools inspector in your browser to see how the example project did this. The basic concept is to make the the <a> take up the entire size of the <li>.