DEV Community

loading...
Cover image for Week 5 at Javascript Bootcamp! *React*

Week 5 at Javascript Bootcamp! *React*

codetivated profile image Melissa Heying Updated on ・2 min read

Hello all 🎉! This week started off confusing AF because we were introduced to React. Everything I thought I new about Javascript changed. But, at the end of the week, I've realized, React has changed Javascript for the better!

Below is my current interpretation of what React is to me. Feel free to correct any wrongs as I am still learning!

Firstly, React describes itself as "A JavaScript library for building user interfaces". It was created by Facebook and is a tool used to create UI components. What does this mean?

To break it down into a visualization, think of React as a piece of cake. This cake has many layers of ingredients or components that make up the entire cake. We're going to look at this cake from top to bottom. The outside layer is your frosting or ROOT. It holds the main index.js file, the App.js file, the HTML file, and the CSS file. Underneath the frosting, is the actual cake.

The first layer of cake called components, is a directory that holds an index.js file. This file exports all the ingredients that are used to make the entire cake. (This is what the frosting imports). The rest of the layers can have as many ingredients or components as you want, as long as it makes a delicious cake!

Hopefully that helped paint a little picture in your mind. If not, at least I tried, lol. 🙈

Before Bootcamp, I purchased a little React course on Udemy and totally forgot about it. I put that course to good use and was able to create an app called "Monster Rolodex". This helped me understand React so much more. I was able to fetch data, used componentDidMount() and was able to fully understand the difference between a functional component and class component . Even though there is still a lot to learn, I'm getting the hang of it!

Can't wait to see what this week has in store! 💚

Discussion (1)

pic
Editor guide
Collapse
codefinity profile image
Manav Misra

Nice analogy. 🍰