Skip to main content

Using component property's value as variable

  • November 17, 2022
  • 1 reply
  • 266 views

Ties

How nice would it be if a value of a component’s property can be used as value of a different property of the same component?

Let’s say you’re designing a screen where the user can change the size of another component by pressing a button. The button component not only has a label, but also an icon, via a property each icon has its own value. As you name those values carefully, you want to use those values as a variable or the button labels. In the ideal world you’d type something like $size as value for the text property of the button’s label, and it would change the value of the text property after selecting a value of the other property, for every individual button (because why type it every time?)

This topic has been closed for replies.

  • February 15, 2023

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings