Flet for Python - easily build interactive multi-platform apps in Python
Project description
Flet - quickly build interactive apps for web, desktop and mobile in Python
Flet is a rich User Interface (UI) framework to quickly build interactive web, desktop and mobile apps in Python without prior knowledge of web technologies like HTTP, HTML, CSS or JavaSscript. You build UI with controls based on Flutter widgets to ensure your programs look cool and professional.
Requirements
- Python 3.7 or above on Windows, Linux or macOS
Installation
pip install flet
Create the app
Create main.py
file with the following content:
import flet as ft
def main(page: ft.Page):
page.title = "Flet counter example"
page.vertical_alignment = ft.MainAxisAlignment.CENTER
txt_number = ft.TextField(value="0", text_align=ft.TextAlign.RIGHT, width=100)
def minus_click(e):
txt_number.value = str(int(txt_number.value) - 1)
page.update()
def plus_click(e):
txt_number.value = str(int(txt_number.value) + 1)
page.update()
page.add(
ft.Row(
[
ft.IconButton(ft.icons.REMOVE, on_click=minus_click),
txt_number,
ft.IconButton(ft.icons.ADD, on_click=plus_click),
],
alignment=ft.MainAxisAlignment.CENTER,
)
)
ft.app(main)
Run as a desktop app
The following command will start the app in a native OS window:
flet run main.py
Run as a web app
The following command will start the app as a web app:
flet run --web main.py
Learn more
Visit Flet website.
Continue with Python guide to learn how to make a real app.
Browse for more Flet examples.
Join to a conversation on Flet Discord server.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file robocorp_flet-0.4.2.1.tar.gz
.
File metadata
- Download URL: robocorp_flet-0.4.2.1.tar.gz
- Upload date:
- Size: 31.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | a41991be51857ba4b0defaa9632856c08eba23fc48511ce11b5c2fe4c36bbe58 |
|
MD5 | 5e465be3039d8c7cd069278325817448 |
|
BLAKE2b-256 | 36701c8350911bc3cfd309e538a47a5b77f774855704e7ab9ae820df1d0ac19a |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-win_amd64.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-win_amd64.whl
- Upload date:
- Size: 19.5 MB
- Tags: Python 3, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 68e0579238318c6f95f2a3e2a6f52a6f607f4262ca249e14320e42cae2e98155 |
|
MD5 | a9f3d2fcdaeed84f29c1d02c438d9f80 |
|
BLAKE2b-256 | 3af4740da07991ce8292c982de55e81fa886513bc6c035b1b5394fc34d9f03b2 |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 17.6 MB
- Tags: Python 3, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d62250fe9663b2f63a3e5ee86e3d2837d74a4f3bee4b38f1b8b54956a5df5383 |
|
MD5 | 3ff9056e91d75bd3c6402d6e979437d1 |
|
BLAKE2b-256 | 308f57d54665e09ff80c5ce605a400008b14f03e7a9f00ceeabdbbe59c76faea |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 16.3 MB
- Tags: Python 3, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 03d1c82511d770cb805bc980007ecc4e350a08531897a9a1b0706e6cd2cc9c36 |
|
MD5 | 960ce250ca33043b218a8554121d9958 |
|
BLAKE2b-256 | 8f62767477b226d328dbae6889513c8c73d000dd9a57b084bd65b8f8beabc578 |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-macosx_12_0_arm64.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-macosx_12_0_arm64.whl
- Upload date:
- Size: 31.0 MB
- Tags: Python 3, macOS 12.0+ ARM64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0d77c00ea63163b8acf4355ca51f7ebc0845011c0ec1f39b117b83a615d96321 |
|
MD5 | 7e8aad8609c7c87a2c516108ccb78443 |
|
BLAKE2b-256 | ae5ba2a7f661f673756c650c2ea275050c796dfb812c1faedb8249ca85ef5d3f |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-macosx_10_14_x86_64.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-macosx_10_14_x86_64.whl
- Upload date:
- Size: 31.0 MB
- Tags: Python 3, macOS 10.14+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8529905dd593d76abef591939a961eac46d6950c28defd3aa9eaddf7e5bf76e5 |
|
MD5 | 469bfebb64a8e891dec7f1d8889b033c |
|
BLAKE2b-256 | db5f7d4df4058c1f370cf1e705a8bec25568c37e4528b8bc392abb04c71d9131 |
File details
Details for the file robocorp_flet-0.4.2.1-py3-none-any.whl
.
File metadata
- Download URL: robocorp_flet-0.4.2.1-py3-none-any.whl
- Upload date:
- Size: 41.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b6f0b7561dc686db28a5c53cc86893361b8ab4f35783bf78bc36db830bfce429 |
|
MD5 | 12e050ad5fb4e532de87519f372d7313 |
|
BLAKE2b-256 | 6d4d5747d5d9e0fb4e95a103e26fe78087b5cc09b122adb3d28a5032b2282758 |