Production-ready, one-click deployable boilerplate for React, Webpack, Flask and PostgreSQL.
This is what you will get:
https://flask-react-boilerplate.herokuapp.com/
You'll neel a little more than one click.
Prerequisites:
- Pip (https://pip.pypa.io/en/latest/installing.html)
- PostgreSQL (http://www.postgresql.org/download/)
- NPM (https://docs.npmjs.com/getting-started/installing-node)
Clone repository:
git clone https://github.com/alexkuz/flask-react-boilerplate.git
cd react-webpack-boilerplate
Install npm dependencies:
npm install
Setup python environment and install dependencies:
virtualenv venv
source venv/bin/activate # or venv/bin/activate.fish or whatever
pip install -r requirements.txt
Copy .env.example
config file to .env
:
cp .env.example .env
Start PostgreSQL service if needed:
pg_ctl -D /usr/local/var/postgres -l /usr/local/var/postgres/server.log start
Create database tables:
heroku local initdb
Finally, start local server:
heroku local web
open http://localhost:3001
- A basket of kittens 🐱
- Simple Flask API, powered with Flask-RESTful, SQLAlchemy and PostgreSQL
- UI, powered with React, Babel, Webpack and React Transform HMR
Copyright 2015, Alexander Kuznetsov <alexkuz@gmail.com>
This boilerplate is based on React Webpack Boilerplate: MIT © Søren Brokær