Loading video...
Video Failed to Load
CSS Tip! 🍬 You can create a CSS-only sticky CTA using position: sticky or scroll-driven animations 🤙 .cta { position: sticky; margin-top: 110vh; bottom: 2rem; /* 👈 Stick! */ } This is one way 👀 This first way relies on you setting a layout on the body and putting... show more
133,003 views • 2 years ago •via X (Twitter)
10 Comments

jhey ▲🐻🎈2 years ago
Here's that @CodePen link! 🤙 Tried it out in Chrome, Safari, Firefox, and iOS. Should be all good 🙏

Jason Torres2 years ago
Just plain wow man.

freddie2 years ago
the margin top idea is already genius by itself, but after reading the scroll driven animation code, I’m so happy to be living in this day and age of css

Okorite2 years ago
wow

リ 乇 刀 卂 丅 丂 口 乙 乇 𠘨2 years ago
I make it by using scrollY .. I make it visible when scrollY is more than a specific pixel.

jiafeng wang2 years ago
nice

Abhishek Rawat2 years ago
Just the time I decide that I've known enough CSS, this man tweets. 😅😭

jhey ▲🐻🎈2 years ago
Haha 🙏

George2 years ago
You are god.

Joshsanger.eth2 years ago
This is awesome. Love the different approaches. The animation-timeline is my fav! Can't wait for Safari to get there. Also the number of open tabs is the cherry on top! 🙈😅
