Keeping Standards High

21 Sep 2023

The Absence of Standards

Throughout my time as a computer engineering student, I have worked with quite a lot of different people and viewed many different versions of the same programs. This is mostly the result of the lack of any sort of enforcement of coding standards in our courses. For example, someone might want to write out 20 if-else statements while someone else will prefer to use a switch statement. Because of these differences in styles, I noticed that it would take varying amounts of time to analyze code depending on how similar it was to your own style.

Are Coding Standards Really That Important?

The importance of coding standards really varies depending on the specifics of a job. In a large company with dozens or even hundreds of software developers, having coding standards is a must. If each developer could write and push code in their own style, the overall repository would be a mess, and analyzing it would be quite a difficult task. However, in the case of a smaller work environment like a school group project, I think coding standards don’t have to be as strict. In fact, I think not having these coding standards can allow for more creativity and freedom to code in a way people are more comfortable with.

My Experiences with ESLint

Prior to ESLint, I wrote my programs in whatever way I felt most comfortable with. Therefore, being conditioned to use ESLint was hard for me initially due to it requiring different formatting of code. One of the standards in ESLint that I am definitely not a fan of is how it wants if-else statements. I personally write every if-else statement on a new line but ESLint requires you to start the next statement at the end of the previous. However, if we were to just skip over that one standard, I think ESLint has made me change some habits that allow me to be a better and more efficient programmer.