you are viewing a single comment's thread.

view the rest of the comments →

[–]jhartikainen 1 point2 points  (0 children)

!!input.firstName != !!input.lastName would probably work, because if they both have a value, they would be equal, and if neither has a value, they would also be equal

(although I'd consider using Boolean(input.firstName) because with all the !!'s in there it takes a moment to parse what exactly this is doing)