1. What is React ? Why we should Learn React? How does react work?

What is Reactjs?


 

React.js  builds user interfaces for single-page web apps by dividing the UI into composable elements. React.Js is a UI library, that was originally developed as an in-house library for Facebook, and then it was later open-sourced in 2013. It's famous and mostly used for a multitude of reasons.

Why we should learn Reactjs?

  1. Learning Curve - which is basically non-existent. 
  2. Community
  3. Speed of React itself  

1. Learning Curve:

React builds off of what you already know i.e javascript. It adds few enhancements like JSX. So we will be able to build those real-world meaningful production ready applications.

2.Community:

React has best communities out there. Good Tool with bad community equal to bad experience. when you have good tool with great community it's a great developer experience. 

So if you have any questions stackoverflow has answers.

We don't to waste time building up really core things.

Facebook, Netflix, Uber, Walmart they are making heavy investments in react and the ecosystem and it's getting better every single day.

You have libraries that can get those common things done like date pickers and so on.

3.Speed of React itself:

A component is a just piece of your UI render five or six components to the screen and you have a complete to the screen and you have a complete site. 

This is a component based architecture makes better  bigger production apps easy. Bigger apps break it up into bunch of little pieces.

Those little pieces  are re-usable easy to build and easy to de-bug.

React renders, re-render the application very quickly.

When we change anything in the js file, the latest data will shown automatically to the user. 

They are really very fast.

How to setup Machine?

There are few things we have to install & configure. Once we have those in place, we will actually be ready to write with react code.

Text Editor Setup: Sublime, Microsoft Visual Studio

Prerequisite for react js:

  1. Basics of Javascript
  2. HTML
  3. CSS 
Here We will use  Microsoft Visual Studio. It is already fantastic tool. This is an opensource software. This also available on MAC, Windows and LINUX.

How does React Work? 

React creates virtual DOM in memory. 

React only changes what needs to be changed.

Installing Nodejs and yarn or npm.

We have to install two tools Nodejs and yarn or npm..

We will be using these two tools extensively throughout the tutorial.

Download Nodejs Setup file from https://nodejs.dev/

Download yarn from yarnpkg.com

What is Node?

Node.js is a free, open-sourced, cross-platform JavaScript run-time environment that lets developers write command line tools and server-side scripts outside of a browser.

We will be creating prod web server.

Check node -v to check the node version.

npm and yarn both will be aiming to get the same job done.

Getting Started: Installing React

Now we all done with the setup.

we will learn how to setup webserver and JSX in the next tutorial


Happy coding!



 

Comments