Django React Typescript screenshot

Django React Typescript

Updated: 17 Jul 2024
384 Stars

This is a non-opinionated Django 5 + React 18 boilerplate built with great development experience and easy deployment in mind.

Categories

Overview:

The Django-React boilerplate is a fully-featured framework designed to provide a great development experience and easy deployment. It combines the Django backend with the React frontend, offering a comprehensive solution for building web applications. With a range of features and integrations, this boilerplate streamlines the development process and ensures efficient deployment.

Features:

  • SSR ready: In progress
  • Service workers: ✔️
  • Gzip static file gen: ✔️
  • Cache control: ✔️
  • Code split and lazy loading: ✔️
  • Google Analytics ready: ✔️
  • PWA ready: ✔️
  • Token authentication: ✔️
  • SMTP ready: ✔️
  • Docker image featuring Memcached: ✔️
  • PostgreSQL: In progress
  • Supervisor (optional): Should be used if deploying on a non-virtualized system
  • NGINX config file: ✔️
  • CI/CD to any V.M. (AWS EC2s, GCloud apps, Digital Ocean droplets, Hostgator VPSs, etc) accessible via SSH: ✔️
  • CI/CD to deploy straight on host (without virtualization; not recommended): ✔️
  • Integrations: Sentry, Cloudinary, Twilio, Google Analytics

Installation:

To use the Django-React boilerplate, follow these steps:

  1. Clone the repository: git clone https://github.com/marcelovicentegc/django-react-typescript.git
  2. Create a virtual environment: python -m venv venv
  3. Activate the virtual environment: source venv/bin/activate or venv\Scripts\activate (Windows)
  4. Install dependencies: npm i && pip install -r requirements.txt && cd frontend && npm i
  5. Set up the project’s .env file by referring to the example .env.example in the root folder.
  6. Set up the frontend app’s frontend/.env file using the example frontend/.env.example.
  7. Start the application: npm start (make sure Postgres is up and running)

Summary:

The Django-React boilerplate is a powerful tool for developing web applications. It offers a range of features, including SSR readiness, service workers, cache control, and token authentication. With integrations such as Sentry, Cloudinary, Twilio, and Google Analytics, this boilerplate provides a comprehensive solution for building and deploying web applications. The installation process is straightforward, and the boilerplate can be customized using the provided .env files. Overall, this is an excellent choice for developers looking for a robust Django-React framework.