Streaming live at 10am (PST)

Anchors not working when page first loads

Hello!

I’m having some problems with anchors when my site first loads. The first time the two main CTAs are hit, they fall short of the anchors. But when they are pressed after the first time then they work…

I’ve spent a couple hours testing everything but can’t work it out. Any ideas? Feels like a potential bug?

Heres the design: Webflow - CMD

Thanks in advance for any help!

Mark

Hello @DarkMiffey

From what I can see they work from first try, both in chrome and safari.

If by falling short you mean anchors don’t scroll to your exact place ( few pixels off ) you can solve that by adding div blocks inside of the sections you want to scroll to and give them ID’s instead of to the sections. You can position them absolute with -100px for example to calculate for the nav bump as well.

Another thing you could do is use data-scroll custom div attributes, eg.

Let me know if this helps, cheers!

It’s definitely falling short for me. On desktop ifs not so obvious but it’s clear on mobile.

Try the live site on mobile: https://www.cmdwindowcleaning.co.uk/

I will try the data scroll custom div. Thanks!