Enabling backToTop abruptly jumps to the top of the page when using this plugin along with Bootstrap v4 tabs. Plus, it would be ideal to scroll to where the tabs start, and not at the very top of the page. What if the tab section is in the middle of the page?
// My current code.
// I tried adding the scrollTo so the page would scroll instead of jump, but it fails.
$(function() {
var backToTop = function() {
if (settings.backToTop === true) {
window.scrollTo(0, 0);
document.body.scrollTop;
}
}
var options = {
backToTop: true
};
$('.nav-tabs').stickyTabs( options );
});
Enabling
backToTop
abruptly jumps to the top of the page when using this plugin along with Bootstrap v4 tabs. Plus, it would be ideal to scroll to where the tabs start, and not at the very top of the page. What if the tab section is in the middle of the page?