Skip to main content

Hi community!

Is there any way I can store and use the current dynamic value of a component e.g. the current width of a button. A button e.g. gets automatically wider with autolayout.


❓ Is there a way to get that value, store it and apply it to other objects?


Thanks a lot in advance ❤️

Sure thing mate. Just check the docs, they are quite comprehensive


Could you perhaps point me to where that’s described or maybe explain how to do it?


Sure, docs are here → https://www.figma.com/developers/api


Thanks, but I’m looking for a way how to do that in the UI, I’m a designer, not a developer.

I know I can store values in variables but then they are set.

Let’s say



  • button A has a text that makes the button 100px wide.

  • button B has a text that makes the button 200px wide.

    How can I the current width value of each button and dynamically write it into a variable?


To code something you’d have to invest some of your time to learn basic stuff. If you haven’t made your “Hello Word” yet it’s time 😉 Good luck mate