Fabian W Posted January 19, 2023 Share Posted January 19, 2023 Hi guys, super simpel questions, the other Forum Threads are a bit too complex for my use case. How to make an element sticky with ScrollSmoother? I do want to have /mimic the same effect: The element pins to a top value as long as it is within it's parent element. Would be great if you could help me out what to do. Thanks, F See the Pen zYLPpzP by anothercodepen (@anothercodepen) on CodePen Link to comment Share on other sites More sharing options...
Solution mvaneijgen Posted January 19, 2023 Solution Share Posted January 19, 2023 ScrollSmoother works great with ScrollTrigger, so I would leverage the power of the two to pin elements on the page. Here is an example. Hope it helps and happy tweening! See the Pen gOjXejj?editors=1011 by mvaneijgen (@mvaneijgen) on CodePen 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now