I have a menu, when I clicked on each nav, it used to animate to resume on that specific section.
Somehow, now it didn't do that anymore recently.
What should I check? I see nothing in my console.
Live : https://www.bunlongheng.com/
I used JS
This is the snippet
$('#main-menu').onePageNav({
currentClass: "active",
changeHash: false,
scrollThreshold: 0.5,
scrollSpeed: 750,
filter: "",
easing: "swing"
});
You only need to add this one line of code.
$('html').css("scroll-behavior", "smooth");
if you were using css then you're missing this line scroll-behavior: smooth;
and if u were using js then please provide a snippet :) thanks for your collaboration.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With