Posts

To create a simple CRUD (Create, Read, Update, Delete) application using React.js for the frontend and Django as the backend

Image
 To create a simple CRUD (Create, Read, Update, Delete) application using React.js for the frontend and Django as the backend , we’ll break it down into two parts: Backend: Django API (using Django Rest Framework) 1. Install Django & Django Rest Framework &   Install django-cors-headers  : First, you need to set up your Django project if you haven't already. pip install django djangorestframework pip install django-cors-headers 2. Create a new Django project: django-admin startproject school_management cd school_management 3. Create a Django app: python manage.py startapp students 4. Configure INSTALLED_APPS in school_management/settings.py : # Application definition INSTALLED_APPS = [         'rest_framework' ,     'students' ,     'corsheaders' , ] MIDDLEWARE = [         'corsheaders.middleware.CorsMiddleware' , ] CORS_ALLOWED_ORIGINS = [     "http://localhost:3000" , ...