News for hackers. Stuff that matters.
Re:Elm for the Front End, Right Now by fnovd on Wednesday November 23, 2016 @08:35PM (#13027268)
>You can not use if "statements" as expressions in Javascript (which sucks quite a bit).

It does indeed, and it leads to some ugly code:

a = function() { if(1>0) { return "Yay" } else { return "Nay" } }()

Re:Elm for the Front End, Right Now by ziad-saab on Wednesday November 23, 2016 @09:27PM (#13027532)
You can also write:

a = 1 > 0 ? "Yay" : "Nay"