Lenis
lenis
How smooth scroll should be
Utilities
scroll
smooth
lenis
react
vue
Utilities
javascript
npm
frontend
open source
Stars
16k
Weekly
1.3M
Open issues
22
Bundle
~25 kB
Installation
npm install lenisCode example
import { useLenis } from "lenis";
export function Example() {
const value = useLenis();
return <p>{String(value)}</p>;
}Pros & cons
Pros
- Actively maintained by darkroom.engineering
- 1.3M weekly downloads. Battle tested
- First-class TypeScript definitions
- MIT licensed
Considerations
- Adds roughly ~25 kB to your bundle
- Needs client-only rendering in SSR frameworks
- Not supported in React Native
- 22 open issues on GitHub