Upgrade & Secure Your Future with DevOps, SRE, DevSecOps, MLOps!

We spend hours on Instagram and YouTube and waste money on coffee and fast food, but won’t spend 30 minutes a day learning skills to boost our careers.
Master in DevOps, SRE, DevSecOps & MLOps!

Learn from Guru Rajesh Kumar and double your salary in just one year.



Get Started Now!

Crud operation in Laravel with react js

Uncategorized

React project

First of all create react project

create a project using this command my project name

npx create-react-app frontend

then run these command also

npm install bootstarp   //to install bootstarp   
npm install react-router-dom  //for routing
npm install axios    // to get data from api

src/pages/create.js

src/pages/edit.js

src\pages\home.js

src\pages\view.js

src\http.js

src\index.js

src\app.js

Start this project by using “npm start”

In Laravel

create a project

composer create-project laravel/laravel:^9.0 <your project name> 

Create Resources controller

UserController.php

user.php

Create database by using “php artisan migration” .then set your filed name which want to create in table.In this case i am using flied name like (name,emailand password)

after that run this command “php artisan migrate

api.php

Route::resource('users',UserController::class);

Run react project by using this command “npm start”

Run laravel project by using this command “php artisan serve”

0 0 votes
Article Rating
Subscribe
Notify of
guest
2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
2
0
Would love your thoughts, please comment.x
()
x