Skip to content

Instant scrolling when changing pages #880

@RodrigoJuliano

Description

@RodrigoJuliano

Is your feature request related to a problem? Please describe.
If you enable smooth scrolling via css styles, forward navigation makes a animated smooth scroll to the top of the page when loading the page.

Describe the solution you'd like
I think this scroll should always be instantaneous.

One way to get this is by passing the 'behavior' parameter to the scroll function.
Change this:

if (wasPush) scrollTo(0, 0);

To:

 if (wasPush) scrollTo({ top: 0, behavior: 'instant' }); 

Additional context
Relates to #496

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions