Thursday, 4 October 2018

window scroll smooth in safari (looking for solution without using jQuery)

I saw a few posts about this issue and I understood that safari doesn't support it, now I saw only suggestions to do it with jQuery, here is not the case, I have 100% React based app and I don't want to use jQuery only for smooth scroll for safari, can anyone suggest any better / easier idea how to make it done ?

currently I'm using the smooth scrolling with window object, I'll add that it works in perfectly fine in Chrome.

window.scroll({
  top: 0,
  left: 0,
  behavior: 'smooth',
});

thank you!



from window scroll smooth in safari (looking for solution without using jQuery)

No comments:

Post a Comment