Using IntelliJ and ESLint is a gamechanger

20 Sep 2023

Switching over from JSFiddle to IntelliJ, my life programming has become so much easier. With the help from ESLint, I’m able to find where I made a mistake quickly and I’ll admit that my code is readable now.

Getting the ball rolling

The first few days using IntelliJ and ESLint were a disaster. Since IntelliJ is a whole new IDE (integrated development environment) that I never heard before, I definitely had to pull an all-nighter to get used to it. I felt like I was a baby getting thrown into the deep end of the pool. I’ve gotten used to JSFiddle and having to download files, npm install, and create a new repository just to start coding in IntelliJ was making me overwhelmed. Especially when having to finish programming under a time limit, my stress levels were through the roof!

The struggle was worth it

After some time getting used to a whole new environment, I was able to get the hang of it. I found it very helpful to make a template with an already-made HTML file and JS file along with all the files needed for ESLint. All I had to do was make a new repository from the template, clone it, and rename the JS file and the scripts in the HTML file. I even made the template public on my GitHub page so that my friends and fellow students could use the template if needed or get inspiration to make their own template. With this method, I was able to save some time or instead use it towards working on my code and refining it. To save even more time, ESLint is able to fix any errors in the JS file so that I don’t need to waste time nit-picking through lines of code just to find that I forgot a semicolon or misspelled something.

Sadly, all good things come to an end because recently I got some news from my Professor for my ICS 314 class that using a template will not do us any good down the line since many of the files may change. I still find it handy to have a template, at least with an HTML and JS file made and ready to code.

One suggestion that I had for the professors and TAs that create these WODS, is that they should put these files into a folder so that the students just have to press download once. But what do I know since I don’t know what’s to come?

What I’ve been doing

I’ve done some experimenting and found that when working on a practice WOD, I would create a new repository and with each attempt, I would create a branch and not push it to the main branch. This is because I like to practice WODs more than once even after I have a good time, I like to try different methods and functions. Making a branch each time allows me to look back on my previous work and progress, and how much faster I finish each attempt. The reason why I don’t push my code into the main branch is because I like to keep the main branch almost like a template or fresh slate so that I don’t have to make a whole new repository and go through that long process of cloning, etc.

“No thank you, CoPilot.”

IntelliJ does allow us to use CoPilot but I prefer to disable it to test my skills and really solve the WODs on my own. When I did try CoPilot, it was great at finishing a line or two but afterward, it would get messy since CoPilot doesn’t really know what it is trying to do unless you give it an example output. CoPilot has just made me more overwhelmed and wasted even more time trying to solve simple problems so I turned it off altogether.

Life is good!

Overall, my experience with IntelliJ, ESLint, and even GitHub has been amazing. It makes reading and reviewing code easier because of the tricks IntelliJ and ESLint have up their sleeves. I definitely suggest you and others give it a try if you haven’t already. Knowing that we will be working with other IDEs and software, makes me excited for what they have to offer.