Closed cyrillebrotto closed 2 years ago
I had the same problem, but now it works on all mobile. Maybe you should try with this setup:
window.addEventListener("load", () => {
const scroll = new LocomotiveScroll({
el: document.querySelector('[data-scroll-container]'),
smooth: true,
scrollFromAnywhere: true,
multiplier: 1,
getDirection: true,
reloadOnContextChange: true,
touchMultiplier: 3,
smoothMobile: 0,
smartphone: {
smooth: !0,
breakpoint: 766
},
tablet: {
smooth: !0,
breakpoint: 1010
},
});
Thank you but unfortunately it still doesn't work on my Android mobile :-( https://codepen.io/Cyrille-Brotto/pen/zYRVoBa
In your example I don't see data-scroll-section anywhere. Not sure that this is the problem, but I think you should stick to the layout shown in the documentation https://github.com/locomotivemtl/locomotive-scroll#smooth
I added some data-scroll and datascroll-section. I changed smoothMobile to true. Now it works on desktop and mobile :-) Thank you very much
Hello I tested this code. https://codepen.io/Cyrille-Brotto/pen/zYRVoBa It works well on firefox and chrom on desktop. It doesn't work on my Android mobile. Do you have an idea? Thank you