The only way to learn React is by writing React

Be an active participant in your own learning

·

5 min read

It’s Monday afternoon and I’m ready to kick this week off with some good old fashion optimism. I discovered a song on Spotify the other day called ‘Good Morning Sunshine’ and it contained lyrics that I’ve decided represent my coding journey. It said: “We are building a castle together and we're gonna build it, brick by heavy brick. And one day soon, you are gonna look up and you are gonna see what we've been working on this whole time.”

With that, the first question I need to answer is, do I feel in a stronger position than I did two weeks ago? Yes. That’s the short answer. The reason for this is because I've been making good strides in learning React and now my CV and cover letter template is ready to be sent to employers. In my last blog, I said that I wanted to have submitted some applications by the time this entry was made but that hasn’t happened yet. On one hand, it stinks that I haven’t applied sooner. On the other hand, I have the opportunity to go into an application frenzy and fill my Trello board with a log of entries.

I had two shower thoughts the day. One, I can create a React app, remove boilerplate code, create a file structure, create components and test they're working. Two, I'm envious of my cat. I'd like to sleep all day and only wake up to eat and go to the bathroom. In all seriousness, the last time I used React was probably three years ago and since then, it's not something I’ve practised much. Well, like anything, the way to learn React is by writing React. I’m getting better at creating a basic React single-page web application. I’m getting better at React Router, which took me a bit of time to get used to. I’m getting better at installing node packages and I’m getting better at writing README files.

That’s not to say that everything is straightforward. Right now I have a blocker on the track. I’ve built a component called <Alert /> that uses a ternary operator that manipulates the DOM to display a success or error message depending on if a form is submitted correctly. Right now it displays a success message even if the entry fields are empty on submit. Oh, and I have a syntax error that says I can’t import a statement from outside a module. I forget to mention that I had an issue integrating an API into my project but Perry from Command Shift, and Chris Edwards and David helped me overcome it.

That being said, I’m feeling confident in my productivity. I’m being a better participant in my own learning. That means I’m not following a tutorial or walkthrough passively and not understanding what I’m doing. Through spaced learning and repetition I can comfortably initiate a React project and I’m taking that as a small victory in itself because once upon a time it wasn’t easy.

Another victory I’m claiming is submitting my code for review. I say that because sometimes it’s difficult to keep up with the pace of the track and to complete projects on time. I’d like to think that I’d be able to play catch up and come back to my unfinished projects but in reality, it’s like running after a train that’s already left the station. No matter how fast you run, you’ll never make it. So, I was delighted to submit a finished project and get the NASA API image generator sent for a code review. I did have a slight hesitation because it felt like I was about to expose my awful code. Although, that’s the point of the task. Show me what I did well and what I need to improve next time. This time I felt better prepared which left me feeling good about my code. My consistency has improved. The aim is to get 2-4 hours in a day and it’s going well. I don’t get the feeling that I’m hopelessly behind the rest of my cohort at this time. My new approach is what I’m calling my ‘starter for 10’. That means all I have to do is complete ten minutes of code to get over the hurdle of inconsistency because after that it gets much easier.

Outside of the track I’ve had my eye on creating a Realtime Database in Firebase for a while now and I finally built a project with it. I followed along with a Scrimba tutorial that built a shopping list app. I do need to go back and fix a bug with the DB and also prevent duplicate entries. Right now, it can be used by anyone and everyone and I need to make it individual to a user. I also want to change up the styling by adding an animated background. Possibly linear gradient.

I want to end with this. My imposter syndrome is something that I’ve openly spoken about in my blog and on my social media accounts. It’s not a taboo subject and everyone experiences this at some point. I’m assuming it’s for this reason that a member of my cohort approached me for advice on it. I’m grateful to have been asked and this is what I said: “The first thing I tell myself is that it's temporary, it will pass.”

“Make a list of small things you know are manageable because it really helps to rebuild your confidence when you can tick something off. I'd split the list into a couple of 'must haves' and 'nice to haves'.

“Give yourself a temporary distraction. For me, that's running, cycling or watching funny stuff online. Or maybe it's a catch-up with friends.

“Take the time to see how far you've come and try not to be so hard on yourself.”