Hello!
I use if() statements a lot. But I often find myself going back and changing it to a switchif() as the project grows. Is there any reason I shouldn’t always use a switchif() from the start?
Hello!
I use if() statements a lot. But I often find myself going back and changing it to a switchif() as the project grows. Is there any reason I shouldn’t always use a switchif() from the start?
i see no technical reason for avoiding the switchif()
function
i habitually use switchif()
in my projects because its much better, for the following reasons
but i do find that many coda makers find it slightly odd. they are more familiar with the if().
i guess it is a matter of personal preference.
to help others follow the logic, i often separate the different clauses with commented keywords
/*then*/ ... /*else-if*/ ... /*else*/ ... /*end-if*/
as otherwise we only have commas between the clauses and its hard to follow
max
Team SwitchIf() !!!
i found calculations are faster with SwitchIfs then IFs…
but maybe its a product of my imagination
Cheers!
Mel