Skip to content

ldtalent/sushan-reactapp-flask

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Serving a react app with a flask server

Project overview

This project shows how to serve a simple react application created by create-react-app with a flask server.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

Ensure that you have the following tools available on your machine;

  • Git A distributed version control system
  • Python A general purpose programming language
  • node A JavaScript runtime
  • A tool to create isolated Python environments preferably Virtualenv
  • Pip A tool for installing python packages
  • create-react-app A supported way of creating single-page React applications
  • yarn A package manager for javascript

Installing

While in your preferred terminal;

Start by cloning the repository to your local machine

git clone https://github.com/learningdollars/sushan-reactapp-flask.git

cd sushan-reactapp-flask/

Make and activate a python virtual environment using virtualenv

virtualenv venv

source venv/bin/activate

With the virtual environment activated, install the project dependencies for the flask server

pip3 install -r requirements.txt
cd react-app/
yarn install

Serving the application

You can start a local server by running

cd flask-server
python3 main.py

visit http://127.0.0.1:5000/ to view your application.

Built With

  • Flask -A python web framework
  • React - A JavaScript library for building user interfaces

Authors

See also the list of contributors who participated in this project.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published