DEV Community

Discussion on: 15 JavaScript Tips: best practices to simplify your code

Collapse
 
itsjzt profile image
Saurabh Sharma

+1 for writing specialized functions

I wrote some very specific functions, like a year ago. then we went through major refactors but the functions are still there and serve the same purpose.

Although declaring variables are somewhat subjective, some languages like python, recommend to initialize variable when you need them.