|
|
|
|
|
by angusC
5786 days ago
|
|
You said "I don't like the keyword "if" so I'm hiding it with && and || because I haven't thought deep enough about a better way of structuring my code" In addition to talking about ternaries, guards and defaults, the article discusses myriad techniques aimed at replacing conditional logic with entirely non-conditional approaches (both functional and oop).These include function dispatching, function delegation, use of high order functions, functions as data and polymorphism. These techniques aren't going to work for everyone and it would be very cool if you chimed in with your own experiences. What's not cool is misrepresenting the article. |
|