Learning to code has been one of the most challenging things that I have had to accomplish in life. It requires an immense amount of perseverance. The first few days or weeks of learning to code are fine, but then the motivation fades. Right then, the real work begins. What I have learned is that learning to code is not glamorous. It takes hard work, determination, and long hours.
The Wealth of Online Coding Resources
The amazing part about learning to code in 2025 is that there are so many online resources that can help you learn.
The amount of online resources can be overwhelming. I would recommend doing your research on a course or platform
and finding one that fits your specific goals and that resonates with your learning style.
Once you have chosen a course or curriculum it is important that you take the course slowly to truly learn the concepts.
Do not try to rush through the course to get to the end. It’s not about the certificate that you receive at the end
but rather the skills you gain. It is totally okay if you pause a course to learn more about the skills that they just taught.
For example, maybe the course just taught a section about arrays in JavaScript. It is totally acceptable to pause the course to
go research more about arrays and how to use them in JavaScript best. You should try doing projects that focus on arrays to help
solidify that knowledge. Again, it is not about the certificate that you receive at the end but rather the skills that you gain.
Learning in this type of way will help to prevent what the tech industry calls 'Tutorial Hell'. 'Tutorial Hell'
is when someone who is learning to code gets stuck in this loop of doing tutorials and not being able to build something on their own.
Taking the Leap: Building Solo Projects
After going through Scrimba’s 'Learn JavaScript' and 'Introduction to ES6+' courses I knew that I had to begin building projects on my own. By the end of the courses, I was itching to build my own projects. I did not want to get stuck in 'tutorial hell' as I have heard many of the horror stories.
My First Solo Project: A Weather Predictor App
The first solo project that I decided to build was a weather predictor app. I knew that I was not a JavaScript expert yet but I wanted to apply
the skills that I had learned from the courses. I did not really know how to create a weather predictor. I was confident that I could interact
with the DOM (Document Object Model) but there were other parts that I wasn’t so confident with. I didn’t know how to interact with different date formats.
I didn’t know how to make something happen based on the user’s date input.
The gist of the project is that a user will input a date and then based on the date provided the app will display a prediction of the weather. The weather
predicted will be accurate based on the season that the date is in.
Building the Foundation: HTML and CSS
I started off by writing the HTML (Hypertext Markup Language) and the CSS (Cascading Style Sheet) for the project. I was pretty comfortable with doing this as I have a good amount of experience working with these technologies. I chose to use the HTML input type of “date” because this would allow the user to select the date from a calendar or type in the date. It helped eliminate the need for checking if the user’s input was valid in JavaScript.
I started off by writing the HTML (Hypertext Markup Language) and the CSS (Cascading Style Sheet) for the project. I was pretty comfortable with doing this as I have a good amount of experience working with these technologies. I chose to use the HTML input type of “date” because this would allow the user to select the date from a calendar or type in the date. It helped eliminate the need for checking if the user’s input was valid in JavaScript.
Starting Small with JavaScript
After this was completed, I moved over to the Javascript portion. I told myself to start small and take the project step by step. I started by getting the
HTML elements over into JavaScript using 'document.getElementById' and creating an array of months. I also went out and got the various weather assets and
set them equal to variables so that I could add them into arrays.
I used an event listener called a click function to listen for when the user clicks on the “Predict” button. I then continued on to make the various weather
assets appear randomly. My thought process was that I should first get the button working to display the weather assets randomly. I can worry about which weather
assets appear later. So, that’s what I did, I used Math.floor(Math.random() * array.length) to randomly loop through the array and display one of the images.
This was a pretty huge win for me because I had to combine multiple JavaScript topics that I had learned in the courses and make them fit together on my own.
It was proof to myself that I had actually learned from the courses that I took.
Overcoming Challenges with Date Input
At this point in the project, I needed to begin working with the date input. This is honestly what gave me the most trouble as I had never interacted with
dates before. None of the courses that I had taken used dates either. So, it really was uncharted territory so to speak.
I started by Googling the date input type and began to work through the problem slowly but surely. My three main resources were W3Schools, MDN, and Stack overflow.
Over the span of a few days, I was finally able to work through the problem enough to where I was able to get a solution. This was an enormous feat because I not
only learned about a new topic but also proved to myself that I could really do this.