JavaScript Code Smells

"A code smell is a surface indication that usually corresponds to a deeper problem in the system" -CodeSmell by Martin Fowler

As we grow as developers we strive to write more maintainable code, but on our journey we often times don't know what that looks like yet.
Your JavaScript may pass stardard JSHint rules, but that doesn't mean it's legit.
Most developers can smell brittle and fragile code a mile away, but it takes time and training to combat against these smells. Code smells scream to be refactored.

Video

The following video was recorded this year at FluentConf. This is the 30 minute version of the talk.



Types of Smells

The following are the types of smells that he cover throughout the presentation. The names are a bit odd, but he have a weird compulsion to alliterate at times :)

  • Convoluted Code Smell
  • Copy Paste Code Smell
  • Switch Statement Smell
  • The This Abyss Smell
  • Crisp Concatenation Smell
  • jQuery Inquiry
  • Temperamental Timer Smell
  • Repeat Reassign Smell
  • Inappropriate Intimacy Smell
  • Incessant Interaction Smell
  • Anonymous Algorithm Smell
  • Unconfirmed Code Smell
  • Two-Way Data Binding Smell

Slides

You can find the slides from the presentation online at elijahmanor.com/talks/js-smells


Related