This case is used for landing pages, for pages with a lot of content. The default anchor link looks like this:
<p><a href="#mylink">Anchor link </a></p> <div id="mylink"></div>
Sometimes, instead of <div id=”mylink”></div> this code <a name=”mylink”></a> is used, the result will be the same, but w3c validators will complain about the missing href.
In this example, the transition will be instant, but now the trend is smooth transitions, beautiful flips and other features.
The solution is mega simple, in css add this one:
html {scroll-behavior: smooth;}