jquery - Simple scroll to animation flicker -


i using snippet of code found here:

simple jquery scroll anchor or down page...?

i have working fine quick flicker of initial screen each time click scroll. modified script work on div instead of anchor.

does have idea why happening?

thanks

http://www.mniac.com/portfolio/

after testing things in console think (99% certain) problem caused placing the anchor href '#.

you have few options:

1) replace anchor tags else. if replace the anchors p tags example, , change jquery work off p.[class] rather a.[class] should fix problem. (you can keep same anchor styling having cursor:pointer; in css make appear link when mouse on link)

2) prevent default action of link. add return false in links eg <a class="work" href="#" onclick="return false;">work</a>

the reason think may problem because when click anchor "#" default take top of page, think it's taking top of page quickly, returning , scrolling destination.


Comments

Popular posts from this blog

PySide and Qt Properties: Connecting signals from Python to QML -

c# - DevExpress.Wpf.Grid.InfiniteGridSizeException was unhandled -

scala - 'wrong top statement declaration' when using slick in IntelliJ -