Archived topic
Back To Top button conflict when active smooth-scroll behavior smooth
3 replies · Started by Neil on February 4, 2022
I have seen this already asked here: https://generatepress.com/forums/topic/back-to-top-button-conflict-when-active-smooth-scroll-behavior-smooth/ however we are experiencing the same issue.
Was this fixed in v3.1.0?
https://dev.utility-stream.com/ scroll to "Get started today", click to smooth-scroll to near footer. Back to top button then moves very slowly.
As this will be used in many places across the site it would be a lot easier to add the css rather than having to add a class to every link.
As always, thanks in advance for the help. Always appreciated.
Hi there,
We can tell GeneratePress not to add smooth scrolling with a filter:
add_filter( 'generate_back_to_top_js_args', function( $args ) {
$args['smooth'] = false;
return $args;
} );
Let me know if that helps or not :)
@Tom That's perfect. Thank you.
No problem!