React-custom-scrollbars: smooth scrolling

Created on 9 Nov 2017  路  4Comments  路  Source: malte-wessel/react-custom-scrollbars

how can i achieve smooth scrolling ?

Most helpful comment

this.scrollbars.view.scroll({
top: 1000,
left: 0,
behavior: 'smooth'
});

All 4 comments

scroll-behavior css property could be the solution :)

can i use scroll-behavior
don't have good browser coverage 馃槦

Hi, I have the same problem, I was trying with https://github.com/malte-wessel/react-custom-scrollbars/issues/13 but success was only partially because if I was using SpringScrollbars and any onScroll method with animating scrollTop I had a infinite loop problem, because this aminated smooth scroll triggers next onScroll event up to bottom of page. Is there any solution to achieve sth like this: http://idiotwu.github.io/smooth-scrollbar/ or this: https://codepen.io/souporserious/pen/zGgvjK ?

this.scrollbars.view.scroll({
top: 1000,
left: 0,
behavior: 'smooth'
});

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Amdingo picture Amdingo  路  4Comments

luxotus picture luxotus  路  4Comments

webchaz picture webchaz  路  3Comments

umer4ik picture umer4ik  路  4Comments

strobox picture strobox  路  4Comments