Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/khouloudhaddad/flaspy

Flask + React with Vite: Full Stack Web Application (Python Backend & React Frontend)
https://github.com/khouloudhaddad/flaspy

flask-api jsonify python react rest-api

Last synced: about 2 months ago
JSON representation

Flask + React with Vite: Full Stack Web Application (Python Backend & React Frontend)

Awesome Lists containing this project

README

        

# Flaspy
Flaspy is a full-stack web application combining a Flask-based Python backend with a React frontend powered by Vite. This project demonstrates how to integrate a modern JavaScript frontend framework with a Python backend, offering a smooth development experience with fast refresh times and robust build tools.

## Create Front-end

```
npx create-vite
```
- Project name: client
- React
- Javascript
- Proceed with remaining steps

## Create Back-end (Commands are proper to Windows environment)

1- Create a folder "server"
2- Run the following command to create a virtual environment entitled "venv"

```
python -m venv venv
```
3- Activate environment by running the following command
```
venv\Scripts\activate
```
4- Install Flask dependency
```
pip install Flask
```
5- Create "server\main.py" file

6- Enable CORS in server
```
pip install FLASK-CORS
```

## FETCH API
- In the client, install axios
```
npm i axios
```