Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(gatsby): Prefer a user's shouldUpdateScroll over a plugin's #16328

Merged

Conversation

stefanprobst
Copy link
Contributor

When a plugin's and a user's gatsby-browser.js both define a shouldUpdateScroll, we currently pick the result from the plugin. We should allow to overwrite the plugin-defined behavior by the user config.

Fixes #12038

@stefanprobst stefanprobst requested a review from a team as a code owner August 2, 2019 11:46
Copy link
Contributor

@wardpeet wardpeet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't see any issues with this change. Haven't tested it yet so that's something I would like to do.

I added on remark to add a comment so we know why we did this.

packages/gatsby/cache-dir/navigation.js Show resolved Hide resolved
Co-Authored-By: Ward Peeters <ward@coding-tech.com>
Copy link
Contributor

@wardpeet wardpeet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and worked! <3 thanks 😉

@wardpeet wardpeet merged commit f02f366 into gatsbyjs:master Aug 4, 2019
@stefanprobst stefanprobst deleted the prefer-users-shouldupdatescroll branch August 4, 2019 08:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants