I need to set value to a
that depends on a condition.
What is the shortest way to do this with CoffeeScript?
E.g. this is how I'd do it in JavaScript:
a = true ? 5 : 10 # => a = 5
a = false ? 5 : 10 # => a = 10
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…