Skip to main content
Question

Validating two variables (nested conditionals?)


Ivan_jangoux

Is it possible right now to check for two conditions to run an action? I.e. If a=1 and b=1 then do action

Thanks

This topic has been closed for comments

3 replies

tank666
  • 4863 replies
  • July 8, 2023

Yes, of course, you can write such a condition.


Avokadomos
  • Active Member
  • 377 replies
  • July 8, 2023

This is a completely valid condition to write in the condition field:

if a == 1 and b == 1


Adrian_Ward

I’d like to point out that what @Ivan_jangoux was requesting was not nested conditionals, but compound conditionals (where more than one variable is compared in a single statement, combined with a boolean operator such as AND or OR etc).

As of mid 2024, there is a very genuine need for actual nested conditionals (where the outcome of a first comparison dictates what other comparisons might be made, each of which have their own outcomes). This is sorely lacking from Figma and a huge limitation when implementing any kind of prototype that isn’t basic. Currently, it isn’t possible to add another Conditional as the outcome of the “then” or “else” of a parent Conditional. You can only set a variable, navigate, etc. This is a huge limitation.

Working around such limitations results in overly complex prototypes and buggy statements that are frustrating and difficult to maintain.


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