Skip to content
This repository was archived by the owner on Dec 24, 2025. It is now read-only.

Commit ca81cae

Browse files
committed
improve README.md
1 parent 8e640b8 commit ca81cae

File tree

2 files changed

+43
-20
lines changed

2 files changed

+43
-20
lines changed

README.md

Lines changed: 42 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,51 @@
1-
# WebView control for Flet
1+
# flet-webview
22

3-
`WebView` control for Flet.
3+
[![pypi](https://img.shields.io/pypi/v/flet-webview.svg)](https://pypi.python.org/pypi/flet-webview)
4+
[![downloads](https://static.pepy.tech/badge/flet-webview/month)](https://pepy.tech/project/flet-webview)
5+
[![license](https://img.shields.io/github/license/flet-dev/flet-webview.svg)](https://github.com/flet-dev/flet-webview/blob/main/LICENSE)
46

5-
## Usage
7+
A [Flet](https://flet.dev) extension for displaying web content in a WebView.
68

7-
Add `flet-webview` as dependency (`pyproject.toml` or `requirements.txt`) to your Flet project.
9+
It is based on the [webview_flutter](https://pub.dev/packages/webview_flutter)
10+
and [webview_flutter_web](https://pub.dev/packages/webview_flutter_web) Flutter packages.
811

9-
## Example
12+
## Documentation
1013

11-
```py
14+
Detailed documentation to this package can be found [here](https://flet-dev.github.io/flet-webview/).
1215

13-
import flet as ft
16+
## Platform Support
1417

15-
import flet_webview as fwv
18+
This package supports the following platforms:
1619

17-
def main(page: ft.Page):
18-
wv = fwv.WebView(
19-
url="https://flet.dev",
20-
on_page_started=lambda _: print("Page started"),
21-
on_page_ended=lambda _: print("Page ended"),
22-
on_web_resource_error=lambda e: print("Page error:", e.data),
23-
expand=True,
24-
)
25-
page.add(wv)
20+
| Platform | Supported |
21+
|----------|:---------:|
22+
| Windows ||
23+
| macOS ||
24+
| Linux ||
25+
| iOS ||
26+
| Android ||
27+
| Web ||
2628

27-
ft.app(main)
28-
```
29+
## Installation
30+
31+
To install the `flet-webview` package and add it to your project dependencies:
32+
33+
- Using `uv`:
34+
```bash
35+
uv add flet-webview
36+
```
37+
38+
- Using `pip`:
39+
```bash
40+
pip install flet-webview
41+
```
42+
After this, you will have to manually add this package to your `requirements.txt` or `pyproject.toml`.
43+
44+
- Using `poetry`:
45+
```bash
46+
poetry add flet-webview
47+
```
48+
49+
## Examples
50+
51+
For examples, see [this](./examples)

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
[![downloads](https://static.pepy.tech/badge/flet-webview/month)](https://pepy.tech/project/flet-webview)
55
[![license](https://img.shields.io/github/license/flet-dev/flet-webview.svg)](https://github.com/flet-dev/flet-webview/blob/main/LICENSE)
66

7-
A Flet extension to web content in Flet apps using WebView.
7+
A [Flet](https://flet.dev) extension for displaying web content in a WebView.
88

99
It is based on the [webview_flutter](https://pub.dev/packages/webview_flutter)
1010
and [webview_flutter_web](https://pub.dev/packages/webview_flutter_web) Flutter packages.

0 commit comments

Comments
 (0)