top of page

React Features

  • Writer: Anand Nerurkar
    Anand Nerurkar
  • Oct 12, 2023
  • 1 min read

React is a javascript based library which could be used to create reactive and responsive UI.We can add additonal library to create those functionality.


For example:


Routing- routing library

HTTP --- axios library to call backend api

Manaing app state --- redux library

Internationalization

Form validation -- reactform

Animations


It support one way data binding.


2 ways to create React component


Class based

If we have class based componenet, then we can hook life cycle method to call backend api.


Life cycle method

didMount for adding compnent

didUnmount- for deleting compoenet

didUpdate() -- for updating componenet


2. Function based

In Function based, we need to get class based functionality into this , so we need to use hook like useEffect.


Comand to install library

===

For alert messages

npm install --save react-toastify


For Router Functionality

npm install react-router-dom


For Bootstrap

npm install bootstrap --save


For HTTP API Call

npm install --save axios


For react snipper plugin in VS

Install simple react snippet plugin in VS


To creat react app

npx create-react-app react-frontend


To run app

npm start


hit http://localhost:3000 in browser


Function based Implementation

==


ree

In above, we make use of a hook -- useState that enable state initialization. With this function we initialize course array.setCourses is a function to update course array.



ree


 
 
 

Recent Posts

See All

Comments

Rated 0 out of 5 stars.
No ratings yet

Add a rating
  • Facebook
  • Twitter
  • LinkedIn

©2024 by AeeroTech. Proudly created with Wix.com

bottom of page