lilliepy-rebound
suspense tag but for react py
Usage:
two ways to use rebounds:
Rebound(fallback: ComponentType, requestfn: Callable[..., Awaitable]) -> Callable[[ComponentType], ComponentType]inRebound(_component : ComponentType | VdomDict, fallback: ComponentType | VdomDict, requestfn: Callable[..., Awaitable]) -> VdomDict | ComponentType
@Rebound()
This is the way to use the decorator version of Rebounding
from reactpy import component, html, run
from lilliepy_rebound import Rebound
from requests import get
async def get_data():
#expensive request
return get("http://127.0.0.1:5000/hello").json()
@component
@Rebound(fallback=html.h1("Loading..."), requestfn=get_data)
def MyComponent(data):
return html._(
html.h1(f"{data}")
)
run(MyComponent)
the Rebound functions gives a param res to the component it is attached to. res contains the data received when the request is complete
inRebound()
This is the way to use the component version of Rebounding
from reactpy import component, html, run
from lilliepy_rebound import Rebound, inRebound
from requests import get
async def get_data():
#expensive request
return get("http://127.0.0.1:5000/hello").json()
@component
def MyComponent():
return html._(
inRebound(lambda data: html.div(f"Result: {data['data']}"), html.div("Loading..."), get_data)
)
run(MyComponent)
basically the same thing as Rebound but it is a component instead of a decorator
Metadata
Release files for lilliepy-rebound 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| lilliepy_rebound-0.0.1.tar.gz | 2.5 kB | Without provenance | Details for lilliepy_rebound-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| lilliepy_rebound-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for lilliepy_rebound-0.0.1-py3-none-any.whl |
Total release size: 5.4 kB
Release files / lilliepy_rebound-0.0.1.tar.gz
| Download URL | lilliepy_rebound-0.0.1.tar.gz |
|---|---|
| Size | 2.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f5a66e072bc7bce337256418fc70a8517f97b46b5d7158c9492167c2ab3b9ac1
|
|
BLAKE2b-256 checksum How to use checksums |
7eb4ced48114e9ca20b29aec27ae3b498a76773c4de33b6f5b48de785f50dc1b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.2
|
Release files / lilliepy_rebound-0.0.1-py3-none-any.whl
| Download URL | lilliepy_rebound-0.0.1-py3-none-any.whl |
|---|---|
| Size | 2.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fca1edf9a16a8ef11781001f98fce718cbba37ff4c43ae49e06df28fb1ae670c
|
|
BLAKE2b-256 checksum How to use checksums |
b573bf7d99533bcc47e5b5c12b32dad03c00f7e90d751f220a9f21afca071a30
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.2
|
Security for lilliepy-rebound 0.0.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.