Lenis script code
Paste this custom code into Webflow’s Page Settings → Custom Code section and publish the site to apply the changes.
<script src="https://unpkg.com/lenis@1.3.26/dist/lenis.min.js"></script>
<script>
window.addEventListener("DOMContentLoaded", () => {
const lenis = new Lenis({
duration: 1.6,
easing: (t) => 1 - Math.pow(1 - t, 4),
smoothWheel: true,
wheelMultiplier: 0.9,
touchMultiplier: 1,
autoRaf: false
});
if (typeof ScrollTrigger !== "undefined") {
lenis.on("scroll", ScrollTrigger.update);
}
if (typeof gsap !== "undefined") {
gsap.ticker.add((time) => {
lenis.raf(time * 1000);
});
gsap.ticker.lagSmoothing(0);
} else {
function raf(time) {
lenis.raf(time);
requestAnimationFrame(raf);
}
requestAnimationFrame(raf);
}
});
</script>From manual tasks.
To intelligent automation.
Automate repetitive work, connect your favourite tools, and build intelligent workflows that grow with your business.
