Skip to content

This is a template for running Flet with its new FastAPI engine, using flet-route for async routing

License

Notifications You must be signed in to change notification settings

polae/flet-route-async

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Multipage Async Flet App

This Repo: flet-route-async

This is a working project template for Flet using its new FastAPI engine and flet-route for async routing.

It sets up the FletFastAPI flet app server with its assets directory, so you can store and use static files, and load fonts, etc.

The code has been formatted using the default settings in Black.

Your comments are very welcome.

Setup


Here is the deployed Multipage Async Flet App using the new FletFastAPI server on Fly.io.

To run this locally, clone the repo to your PROJECT_ROOT_DIRECTORY.

Navigate to this directory in your terminal.

cd path_to/project_root_directory/

Now in the project root directory, create your virtual environment.

python3.11 -m venv .venv

You may use a different version of python.

Activate the virtual environment.

source .venv/bin/activate 

And install the required packages:

pip install -r requirements.txt

You should now be able to run the app:

uvicorn async:app --reload

View the app at localhost: http://0.0.0.0:8000.

Further

I would also like to understand the best way to deploy this app.

Docs

Flet for FastAPI

Flet-Route

About

This is a template for running Flet with its new FastAPI engine, using flet-route for async routing

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published