LENIS SMOOTH SCROLL IN ELEMENTOR

Learn how to install the amazing “LENIS Smooth Scroll” library in Elementor, and get the AWWWARDS scroll vibe on your Elementor website. 🖥❤️

Sharing Is Caring!
Facebook
Twitter
LinkedIn

DONATE

Help me keep this site and YouTube channel alive. 🖥❤️

.Get the "code"

*Press the Copy button and pate the code on your site. 

				
					<script src="https://cdn.jsdelivr.net/gh/studio-freight/lenis@0.2.28/bundled/lenis.js"></script>

<script>
const lenis = new Lenis({
  duration: 1.2,
  easing: (t) => Math.min(1, 1.001 - Math.pow(2, -10 * t)), // https://www.desmos.com/calculator/brs54l4xou
  direction: 'vertical', // vertical, horizontal
  gestureDirection: 'vertical', // vertical, horizontal, both
  smooth: true,
  mouseMultiplier: 1,
  smoothTouch: false,
  touchMultiplier: 2,
  infinite: false,
})

//get scroll value
lenis.on('scroll', ({ scroll, limit, velocity, direction, progress }) => {
  console.log({ scroll, limit, velocity, direction, progress })
})

function raf(time) {
  lenis.raf(time)
  requestAnimationFrame(raf)
}

requestAnimationFrame(raf)
</script>
				
			
Elementor
Jacob Vinjegaard

Custom Page Loader

Custom Page Loader With Lottie Animation In this video we are setting up a custom page loader with a Lottie animation and JavaScript. 🖥❤️ https://youtu.be/XEd_ylDq_18

Read More »
Elementor
Jacob Vinjegaard

Lenis Smooth Scroll

LENIS SMOOTH SCROLL IN ELEMENTOR Learn how to install the amazing “LENIS Smooth Scroll” library in Elementor, and get the AWWWARDS scroll vibe on your

Read More »