Releases: locomotivemtl/locomotive-scroll
Releases · locomotivemtl/locomotive-scroll
v5.0.1
Locomotive Scroll v5.0.1
Version 5 is a complete rewrite of Locomotive Scroll, now built on top of Lenis.
Highlights
- Lighter & Faster — 9.4kB gzipped (down from ~12.1kB in v4)
- TypeScript First — Fully typed with complete IntelliSense support
- Built on Lenis — Modern smooth scroll engine with native scrollbar
- Dual Intersection Observer Strategy — Optimized detection for triggers vs. continuous animations
- Smart Touch Detection — Parallax auto-disabled on mobile for native scrolling
- Custom Scroll Containers — Full-page or contained scrolling support
- No Layout Shifts — No more greedy CSS transforms breaking your layouts
- Native CustomEvents — No more ModularJS dependency
- New Landing Page — scroll.locomotive.ca
- New Documentation — Completely rewritten docs with examples
Breaking Changes
This version contains breaking changes from v4. Notable removals:
data-scroll-containeranddata-scroll-section(no longer needed)data-scroll-sticky(use CSSposition: sticky)data-scroll-delay,data-scroll-direction,data-scroll-target- ModularJS integration (use native CustomEvents)
- Custom scrollbar (use native scrollbar)
Migration Guide
Upgrading from v4? Check out the Migration Guide for detailed instructions.
Documentation
- Landing Page: scroll.locomotive.ca
- Documentation: scroll.locomotive.ca/docs
- Examples: scroll.locomotive.ca/docs/examples
- Showcase: scroll.locomotive.ca/docs/extras/showcase
Acknowledgements
Special thanks to https://github.com/darkroomengineering for https://github.com/darkroomengineering/lenis, the smooth scroll engine powering v5.
Thanks to all contributors who helped shape this release 🫶
v5.0.0-beta.12
- Update Lenis dependency
- Update to Lenis
v1.0.45
v.5.0.0-beta.11
- Update Lenis to
1.0.29- Fix
rootElement
- Fix
- Export styles and explicitly declare public exports
v5.0.0-beta.9
- Update Lenis to
1.0.27and support its new optionseventsTargetsyncTouchsyncTouchLerptouchInertiaMultiplierautoResize
- Fix
start()/stop()lenis methods not sync with core instsance
Getting closer and closer to a official release!
v5.0.0-beta.8
Subscribe scrollEventProgress option to attributes that need RAF
v5.0.0-beta.7
v5.0.0-beta.7 (2023-05-18)
What's new?
- Now built on top of Lenis 🤝
- Built in TypeScript for a better developer experience
- Built-in viewport detection using browsers's native Intersection Observer API
- Real time progress value for flexible scroll-based animation
- Accessibly and performance more than ever