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

Support parent container for scroll behavior #1249

Closed
erguotou520 opened this issue Mar 14, 2017 · 1 comment
Closed

Support parent container for scroll behavior #1249

erguotou520 opened this issue Mar 14, 2017 · 1 comment

Comments

@erguotou520
Copy link

Feature request?

VueRouter use window.scrollTo to do scroll, but in some case, the scroll container may be not the body, is that possible to support custom scroll parent like:

scrollBehavior () {
  return { container: 'container-selector', x: 0, y: 0 }
}

For realization, update window.scrollTo to $container.scrollTop = position.y; $container.scrollLeft = position.x

@posva
Copy link
Member

posva commented Mar 14, 2017

dup of #1187

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants