DEV Community

Discussion on: A New Coding Style for Switch Statements in JavaScript/TypeScript

Collapse
 
john_papa profile image
John Papa

I love this! I had this exact problem last week and I fell into the same solution. It really bothered me that I had so much duplicate code.

Glad you wrote this up. Highly readable (which I love) and a great tip for everyone.

Nicely done Bryan!