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

What is Framer? Join the Community
Return to index
Caitlin Charniga
Posted Jul 21 - Read on Facebook

Is there an easy way to set the same style for multiple layers? For instance I have form fields and want to just write one style for each different field as opposed to having to copy/paste a bunch of times.

2 Comments

Benjamin Zanatta

Yes. You can create a variable with the style and set it to each field you want.

ex:

myStyle = { "border": "2px solid red"}
layerA = new Layer
layerB = new Layer

layerA.style = myStyle
layerB.style = myStyle

Caitlin Charniga

Thank you!!

Read the entire post on Facebook