Intro To React-1
Intro To React-1
What Is React?
Components are independent and reusable codes. They work for the same
purpose as JavaScript functions but work independently and restore HTML
with render () function. In simple words, react is like the lego game, and here
components are bricks of lego that are used to build different applications.
Class components - The class component name must start with a capital
letter. This component should contain the React.Component statement,
which creates the inheritance for the React.Component and gives your
component access to the functions of the React.Component. The component
also requires a render () method, which provides HTML.
What is a framework?
The framework defines open or non-executed functions or objects that the
user writes to create a custom application. Since Framework is an
application, it has a wide range and includes everything needed to create a
user application tailored to its need.
What is Library?
The library provides a set of auxiliary functions/objects/modules that your
application calls for specific functionality. Libraries usually focus on a narrow
range. The reason we need the library is very simple, i.e. code reuse, use
code already written by other developers.
Model: The model component consists of all data-related logic that works
with the user.
View: The view component is used for all UI logic of the application.
Controller: The controllers act as an interface between the model and the
view components to process all business logic and incoming requests,
modify the data using the model component and interact with the view to
display the final output.
So React is a library that is just the view part of the MVC framework,
whereas other frontend frameworks like angular is an extensive framework
that is more than the view part of the MVC framework. According to Google
statistics, react is easy to learn as it is not so vast and is the most searchable
front-end library.
Some Terminal Commands
Pwd: PWD stands for Print Working Directory. It prints the path to the
working directory starting from the root.
Ls: ls is a shell command that lists directory contents of files and directories.
CD: The CD command in Linux is called the Change Directory Command. It is
used to change the current working directory.
Clear: Clear is the standard operating system command used to clean the
terminal screen.
Summarising It
Resources
Lecture Resources:
● Visual Studio Download Link: https://code.visualstudio.com/download
● NodeJs Download Link: https://nodejs.org/en/download/
Further Readings:
● Single page apps v/s Multi page apps:
https://asperbrothers.com/blog/spa-vs-mpa/
● React v/s Angular Comparison:
https://hackernoon.com/reactjs-vs-angular-comparison-which-is-better
-805c0b8091b1