Whitespace - scrolling to anchor

Hi Colorlib Team!

I’ve got a question related to Whitespace HTML template. So I wanted change this template a bit, and make index.html more of a one-page website. Main navigation should scroll down to anchors/sections, and from the sections there will be regular hyperlinks to other pages.

So I wanted to place a js code as follows: $(document).on('click', 'a[href^="#"]', function (e) { e.preventDefault(); $('html, body').stop().animate({ scrollTop: $($(this).attr('href')).offset().top }, 1000, 'linear'); });
But there appear an issue - navbar stopped working while scroll. So I thought it might be a conflict between my own code and a scroll function from line #138 of main.js file. How can I connect both?

Hi There,

Thanks a bundle for the mail.

Your code is preventing the default anchor click function for the function.

Unfortunately, the HTML templates are provided as they are and we are not able to assist with customization.

Apologies for the inconvenience.