Smooth Scroll with custom anchors
Smooth scroll doesn’t works with custom anchors. Every link (for example #contact) is scrolling to the top of the page. Even after following howto here: https://docs.layerswp.com/doc/how-to-create-a-single-scrolling-page-with-anchor-links/
But with the default anchors (like #layers-widget-column-12) it works without any issue.
I really thank you in advance!
Possible Answers to Your Question:
Assuming you are talking about the snippet in this article:
This is because the function is specifically looking for IDs that use a hash, not for a name attribute, which is what the custom anchors set (widgets can only have one ID).