Skip to content

threat0day/sample-flask-angular

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample Flask with Angular web app

Sample Flask with Angular web app.

App Structure

/
├── LICENSE.md
├── README.md
├── requirements.txt
└── sample-flask-angular # Flask project folder
    ├── angular # Angular project folder
    │   ├── dist
    │   ├── e2e
    │   ├── karma.conf.js
    │   ├── node_modules
    │   ├── package.json
    │   ├── protractor.conf.js
    │   ├── README.md
    │   ├── src
    │   ├── tsconfig.json
    │   └── tslint.json
    └── main.py

Requirements

Install the following requisites:

  • Python3
  • Virtualenv
  • NodeJs
  • Angular-cli

Installation

Create virtual enviroment folder and load:

$ virtualenv -p python3 .venv
$ source .venv/bin/activate

Install python dependencies:

(.venv) $ pip install -r requirements.txt

Install angular dependencies:

$ cd sample-flask-angular/angular
$ npm install

Deployment

First build production application of Angular with Angular-cli:

$ cd sample-flask-angular
$ ng build --prod

Start server:

$ source .venv/bin/activate
(.venv) $ python sample-flask-angular/main.py

Routes

  • /: Index route will serve angular application.
  • /hello: return Flask hello function.

Authors

About

Sample web app with Angular as frontend and Flask as backend

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors