3 ms·
I actually really like the nested ternaries. TypeScript understand them very well and you don't have to extract your code outside the render to start using if/e
by Kaotique 5y ago
I actually really like the nested ternaries. TypeScript understand them very well and you don't have to extract your code outside the render to start using if/else structures. They also format quite well.
- eyelidlessness 5y agoI like ternary conditionals, nested or otherwise. But I also like reduce. And regular expressions. And I know a lot of other devs hate some or all of them. So I tend to use them sparingly when working with a team… although I do see more ternaries in idiomatic code these days, generally as devs embrace a more FP style.