Why did I write that before??

09 Feb 2023

As long as it works, right?

Coding standards are rules/guidelines for developers to follow to achieve cleaner and readable code. I did not realize how important coding standards were until I was working on a personal project. Because the code I was writing was not for school, meaning I would not get points deducted for not following coding standards, I was just “doing my own thing.” I had that misconception, that as long as the code works, I am “all good.” However, it was not until days later, when I looked back at my code and realized there were certain parts that I did not know why I wrote that/what it was for. This made me realize that coding standards are useful, as I was spending time trying to figure out my own code that I had wrote. From this experience, I do believe that coding standards are important because it increases efficiency and productivity, as well as making your code look neater. It will also make things easier in the long run if you have to go back to your code and you want to change something or add on to your project.

ESLint with IntelliJ

This week in class, we were introduced to ESLint and IntelliJ. ESLint is the tool we are using to automatically check our code for being in compliance with coding standards. If there are no ESLint errors, then this is illustrated with a green checkmark on the right hand corner of IntelliJ. Compared to the previous IDE I used in prior classes, which was JGRASP, I do prefer IntelliJ so much better. Conforming to the coding standards of ESLint can be a bit tedious sometimes and will take a bit to getting used to (for example, like not using double quotes for strings, which is what I personally prefer over single quotes). I do appreciate how checking for errors is so much easier (F2 is now my friend) and it is satisfying receiving the green checkmark after.

Although coding standards can be tedious sometimes, in the end, it is important especially when you are working on a larger codebase. Part of working as a developer will come with working in a team and collaboration. Therefore, with coding standards that everyone follows, it will be easier for you when you have to read someone else’s code and vice versa.