Skip to content

Reset Scroll Position after page is loaded #3249

@ziyafenn

Description

@ziyafenn

Description

Each time i load new page, the scroll position stays same as it was on the previous page.
I want to reset the scroll position each time page is reloaded.

Environment

Gatsby version: 1.9.130
Node.js version: 6.10.2
Operating System: mac OS High Sierra

File contents (if changed):

gatsby-config.js:
package.json:
gatsby-node.js:
gatsby-browser.js:
gatsby-ssr.js:

Steps to reproduce

I've tried all solutions mentioned here: https://stackoverflow.com/questions/33188994/scroll-to-the-top-of-the-page-after-render-in-react-js and none of it helped. (i was adding those to html.js)

...

Metadata

Metadata

Assignees

Labels

type: bugAn issue or pull request relating to a bug in Gatsby

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions