Menu

The 4 bugs that break Astro + GSAP + Lenis in production (and how I fixed them)
📰

The 4 bugs that break Astro + GSAP + Lenis in production (and how I fixed them)

DEV Community: javascript·Keymel Gaston·16 days ago
#zd0oqKbv
#devtojavascript#devto#dev#lenis#astro
Long article (625 words) — no AI summary yet.
Reading 0:00
15s threshold

If you’ve been building creative landing pages with Astro + GSAP + Lenis, you’ve probably noticed a frustrating pattern: most starters look absolutely stunning in the demo, but fall apart the moment you deploy them to production.

I got tired of losing hours debugging the same issues across multiple client projects. So, I dug into the root causes and fixed the four specific bugs that usually cause this at the configuration level.

Here is the technical breakdown of what breaks, and exactly how to fix it.

Bug 1: Scroll-triggered animations silently never fire

The problem: Lenis replaces native scroll with a virtual one. If GSAP’s ScrollTrigger isn’t explicitly synced to it, it never detects scroll at all. Your animations just… don’t run.…

Continue reading — create a free account

Join HashtagPLUS to read full articles, follow hashtags, vote, and join the conversation.