DEV Community

Discussion on: Why I prefer objects over switch statements

Collapse
 
davidchase profile image
David Chase

Just a quick example of an alternative to the OPs object hash its similar to clojuredocs.org/clojure.core/cond or if you prefer JS ramdajs.com/docs/#cond