I got ready for starting my summer project which was a boilerplate for NodeJS apps. I had only finished a few courses and online tutorials on node with express routing and login features using PassportJS. It took me a while to navigate through all the docs and stackoverflow to finally finish the app and I thought gained a lot of knowledge on making and deploying a proper app, I was already celebrating that I was now intermediate level profecient in JS.
I was interviewing for a web dev internship. I was really excited since I was confident in what I knew. He started of basic with some troubleshooting questions, asking about myself and my projects etc. now he asked me another pretty basic question: I enter a email into a textfeild and submit it, how do check if its valid on the backend? pretty general but looking back to my project I just used a dependency and called a function to check its validity in a controller .js file I had no idea how the check actually works. I assumed its a simple loop to check for the @ and get info after that and told my interviewer the same. Well turns out that answer was not even close to being right.
The answer the interviewer was expecting was using regex to check the pattern which will give us a result faster and told me that looping is actually not efficient nor usable at all.
Then it hit me hard, the misconception that I knew making a nodejs app which in reality I had no idea HOW my code does what its doing. I knew I could just import a dependency for validation, sanitization and other features but did I know HOW they work? the simple answer was nope.
Always learn HOW the language/framework/dependency works and not just calling it. Even a college freshman can search up code copy paste it and learn it a bit to make it work but I want everyone to realize from my experience that you might be missing the most important and fun part of learning!