This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Edward Sanchez
Posted Aug 22 - Read on Facebook

How can I continuously track the position of an animated layer?
I can get the X Position as a variable when I have an event like DragMove, but once I release I no longer get it.

Would I have to do something like setInterval to poll the position every few milliseconds?

3 Comments

Mike Feldstein

A neat trick i found on this page is you can listen to "change:x" events on a layer. Then you can have just one listener, instead of one for drag events and one for animation events.

I've often wanted an Events.AnimationUpdate event, but it's not there yet.

Edward Sanchez

oh thank you! Would you mind explaining how to set up a listener? I haven't figured out how to do it in CS.

Read the entire post on Facebook