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

What is Framer? Join the Community
Return to index
John Grendon Enderby
Posted Jul 07 - Read on Facebook

Hey folks!

Just wondering about if statements in framer. Is it possible to do something like:

if oneItem.visible is true or twoItem.visible is true
mask2.visible = false
mask2.visible = true

Not sure if I have done the if/else right or not but could really use some help :)


Balraj Chana

Hey John, Framer uses coffeescript and flow control can be written either the way you have just described, or on one line like this:

mask2.visible = if oneItem.visible or twoItem.visible is true then false else true

John Grendon Enderby

so the above should work then?

Balraj Chana

That's right :) (with the correct indentation)

John Grendon Enderby


John Grendon Enderby

thanks very much

Read the entire post on Facebook