Jump to content
Search Community

Super simple GSAP tied to scroll.

jesper.landberg test
Moderator Tag

Warning: Please note

This thread was started before GSAP 3 was released. Some information, especially the syntax, may be out of date for GSAP 3. Please see the GSAP 3 migration guide and release notes for more information about how to update the code to GSAP 3's syntax. 

Recommended Posts

Hi,

 

I'm trying to create a personal little mini lib/class to handle timelines tied to scroll. Could use ScrollMagic, but wouldn't learn much from that would I?

 

Any feedback on what is done so far? Thinking about how I would play more advanced timelines, rather than just simple fromTo's. I guess those would be best of defined in the javascript, but trying to think of an elegant solution to that, any tips? Currently I define animations through data attribute, as valid json.

Also, is it possible to get the end bounds/rect of a timeline/tween element in advance? Or would I need to put progress(1) .. get new rect... put back to progress(0) ?
 

See the Pen PxrZdp by ReGGae (@ReGGae) on CodePen

 

See the Pen PxrZdp by ReGGae (@ReGGae) on CodePen

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...