Skip to content
This repository was archived by the owner on Nov 5, 2023. It is now read-only.

Conversation

@hunterliu1003
Copy link
Contributor

@hunterliu1003 hunterliu1003 commented May 31, 2022

Provide options smooth, auto for scrollBehavior

In my use case, I'll open a page with dynamic route id, so the url will be like localhost:3000/users/:userId.
The page has a Grid component that is for displaying all users on the left side, and displaying current user information on the right side depending on the :userId.
So I hope when user refreshing/entering the page, Grid can immediately scroll to the index at the first time instead of smoothly scroll to the index.

That's the reason I need a way to decide when the scrollBehavior is smooth or auto

Please checkout the implementation when you're available, and feel free to let me know if you have better solution thanks.

@netlify
Copy link

netlify bot commented May 31, 2022

👷 Deploy request for vue-virtual-scroll-grid accepted.

Name Link
🔨 Latest commit 1f924f6
🔍 Latest deploy log https://app.netlify.com/sites/vue-virtual-scroll-grid/deploys/6295c1285f028b0008ef0bc9

@mesqueeb
Copy link
Contributor

💯💯💯💯💯

Copy link
Owner

@rocwang rocwang left a comment

Choose a reason for hiding this comment

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

This is great!
Code looks good to me, but would you mind updating the documentation in README.md, under the "Available Props" section?

@hunterliu1003 hunterliu1003 requested a review from rocwang May 31, 2022 09:48
@hunterliu1003
Copy link
Contributor Author

Sure!
I updated the documentation in README.md. Please check again.

Co-authored-by: Luca Ban <mesqueeb@users.noreply.github.com>
@mesqueeb
Copy link
Contributor

mesqueeb commented Jun 1, 2022

@rocwang let me know if you released this one 🙏🏻

@rocwang rocwang merged commit 464d804 into rocwang:main Jun 1, 2022
@github-actions
Copy link

github-actions bot commented Jun 1, 2022

🎉 This PR is included in version 1.5.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants