Flask Noodle | Instant Project Folder Generator

Step-by-Step tutorial using flasknoodle package to quickly generate your Flask Application project folders and files.

Flask Logo
Photo from Flask official Page

Flask is one of the very popular Python frameworks available in the market. It is a lightweight framework which gives developers freedom to customise to their taste.

It has no database abstraction layer, form validation, or any other components where pre-existing third-party libraries provide common functions. However, Flask supports extensions that can add application features as if they were implemented in Flask itself. — Wiki

Why do we need Flasknoodle?

The flasknoodle application helps developers by saving them time that would have been spent writing boiler plate code. Developers can therefore spend more time writing the code that matters. For example, AI/ML engineers can use flasknoodle to quickly generate a working Flask application. They only need to add few endpoints to the original application to serve their models.

Flasknoodle provides one endpoint ‘/’ which serves an index.html file. See example below:

Flask application with single endpoint
Flask Application with only one endpoint

Additional endpoint can easily be added. See example below where the ‘/about’ endpoint was added.

Flask application with two endpoints, i.e. includes user generated endpoint
Flask Application with two endpoints. The ‘/about’ endpoint was added by user

Installing Flasknoodle

Installing virtual environment
Create and activate a virtual environment
Installing flasknoodle package
Install flasknoodle package from PyPI
  • Generate complete Flask project template in current directory (default project name is “server”)
Using “flasknoodle” keyword to generate flask application folder
Generate project folder using keyword flasknoodle
  • cd into application directory (i.e. server folder)
Folder Structure
Generated Flask Application folder
  • Install dependencies from ‘requirements.txt
Installing dependencies
Install dependencies
  • Run Application
Running Flask application
Start Flask application

Conclusion

Pull requests with improvements and fixes are actively welcomed. The whole working repository is available on GitHub.