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

What is Framer? Join the Community
Return to index
Calvin Teoh
Posted Oct 08 - Read on Facebook

Is it possible to get Events from the old native style scrolling (ie. Not using the ScrollComponent but the old layer.scroll method)?

I'm trying to find the position of the scrolled content as it changes, but when querying its y-position, it always remains at '0'

3 Comments

Dave Crow

I tripped over this the first time too. But it can be done with the ScrollComponent.

Use
scrollLayer.content.on "change:y", ->

Calvin Teoh

Thanks Dave, i'm looking to do this without the use of the ScrollComponent, because I need this work with a trackpad. (Desktop prototype)

Marcelo Eduardo Oliveira

Calvin Teoh if you're using a normal scrolling window / div ( even as a framer layer ) try the events on it's "dom" element ( layer._element ) let me know if this is what you need! :)

Read the entire post on Facebook