https://github.com/app-generator/flask-learn-by-coding
Flask Web Framework - Learn by Coding | AppSeed
https://github.com/app-generator/flask-learn-by-coding
appseed-sample flask learn-by-coding
Last synced: about 1 year ago
JSON representation
Flask Web Framework - Learn by Coding | AppSeed
- Host: GitHub
- URL: https://github.com/app-generator/flask-learn-by-coding
- Owner: app-generator
- License: other
- Created: 2019-06-11T05:37:11.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2022-10-11T10:20:08.000Z (over 3 years ago)
- Last Synced: 2025-03-11T05:55:49.777Z (over 1 year ago)
- Topics: appseed-sample, flask, learn-by-coding
- Language: Python
- Homepage: https://appseed.us
- Size: 7.04 MB
- Stars: 5
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Learn Flask by Coding
Open-source project provided by AppSeed to help beginners accommodate faster with Flask. For newcomers, Flask is a lightweight WSGI web application framework. It is designed to make getting started quick and easy, with the ability to scale up to complex applications.
> 🚀 `PROMO`: **[Junior Developers Starter KIT](https://www.creative-tim.com/product/buy/bundle/junior-bundle?AFFILIATE=128200)** `85%OFF`
The package includes a `rock-solid collection of premium assets` (**Kits & Dashboards**) that can be used to build eye-catching portfolios and web apps in no time.
[](https://www.creative-tim.com/product/buy/bundle/junior-bundle?AFFILIATE=128200)
## Getting Started with Flask
> Create a Virtual Environment
```bash
$ # Virtualenv modules installation (Unix-based systems)
$ virtualenv env
$ source env/bin/activate
$
$ # Virtualenv modules installation (Windows-based systems)
$ # virtualenv env
$ # .\env\Scripts\activate
```
> Install `Flask`
```bash
$ pip install flask
```
> Edit your first Flask app `main.py`
```python
from flask import Flask
app = Flask(__name__)
@app.route('/')
def hello_world():
return 'Hello from Flask!'
```
> Setup the environment
```bash
$ # Set the FLASK_APP environment variable
$ (Unix/Mac) export FLASK_APP=main.py
$ (Windows) set FLASK_APP=main.py
$ (Powershell) $env:FLASK_APP = ".\main.py"
```
> Start the app
```bash
$ flask run
$
$ # Access the app in browser: http://127.0.0.1:5000/
```
---
Learn Flask by Coding - Provided and actively supported by AppSeed [App Generator](https://appseed.us)