Skip to main content

spaday

Build Status codecov License PyPI

Build reactive web-component UIs configured in Python, executed in the browser.

Overview

You author a UI as a tree of typed Python components — WebAwesome by default, or any library that ships a Custom Elements Manifest. You attach behavior as declarative data: an action DSL (toggle a prop, send a model edit, call an endpoint) and reactive bindings (a control two-way-bound to a state field, or a prop computed from others). spaday's JavaScript runtime renders the tree to real web components and interprets that behavior client-side — so a toggle or a derived value updates with no round-trip to Python.

That UI state is a transports model, so it syncs over any connection (WebSocket, SSE, Jupyter comm) and any codec; the same tree drops into a web app or a Jupyter notebook unchanged.

Like transports, spaday is a Rust core with thin bindings: the component tree, the diff engine, the CEM parser, the action interpreter, and the reactive engine live in Rust and compile to PyO3 (Python authors the tree) and wasm (the browser runs it). One core, two bindings.

from spaday import Widget
from spaday.components.webawesome import WaCard, WaSwitch

# a switch two-way-bound to a state field, rendered in a Jupyter cell
ui = WaCard().child(WaSwitch().text("Lamp").bind("checked", "on", mode="two-way"))
w = Widget(ui, state={"on": True})
w  # flip the switch → w.state["on"] flips in Python; set w.state → the switch follows

Install

pip install spaday            # core: author + serialize component trees
pip install "spaday[widget]"  # + the Jupyter / anywidget host

Documentation

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spaday-0.2.1.tar.gz (5.4 MB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

spaday-0.2.1-cp311-abi3-manylinux_2_28_x86_64.whl (5.2 MB view details)

Uploaded CPython 3.11+manylinux: glibc 2.28+ x86-64

spaday-0.2.1-cp310-abi3-win_amd64.whl (5.1 MB view details)

Uploaded CPython 3.10+Windows x86-64

spaday-0.2.1-cp310-abi3-macosx_11_0_arm64.whl (5.1 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

File details

Details for the file spaday-0.2.1.tar.gz.

File metadata

  • Download URL: spaday-0.2.1.tar.gz
  • Upload date:
  • Size: 5.4 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for spaday-0.2.1.tar.gz
Algorithm Hash digest
SHA256 056270d874669943cb323356565c2cb653508806d611be0d681de2e238f59bb5
MD5 4d2e78d5da4737c0ffc217c9d6a7ca1f
BLAKE2b-256 9dd3157f497c85e384a589ce164702e3c7b62a94ed4460db578a20621664cac9

See more details on using hashes here.

File details

Details for the file spaday-0.2.1-cp311-abi3-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for spaday-0.2.1-cp311-abi3-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 e88521e6a959ce5f9a350aa9f0082eb0d194514b7b5c5f079bbd8a4216901839
MD5 5c1f102c01e5fcd953e45bf51748311d
BLAKE2b-256 3b36c5f39094a22cdd9a1eef90af0b65f19a776a86493cbced21fa4a1f1df21a

See more details on using hashes here.

File details

Details for the file spaday-0.2.1-cp310-abi3-win_amd64.whl.

File metadata

  • Download URL: spaday-0.2.1-cp310-abi3-win_amd64.whl
  • Upload date:
  • Size: 5.1 MB
  • Tags: CPython 3.10+, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for spaday-0.2.1-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 2d8545c5275872aa6df1abf53677d01dbfeaf5ffe341256b26f8479a95dfb8c5
MD5 bb7fb99a107df6d025693d9e7623c366
BLAKE2b-256 d4008f44e25e1d75de9ca53a9dbf4bf86b6274ebcb6a1ef09c7a671ecc9086e9

See more details on using hashes here.

File details

Details for the file spaday-0.2.1-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for spaday-0.2.1-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 02b34cf140d998b913f02717d4855aa3970503672fae85bece5e2bfd27c76ab0
MD5 492f739b549642b333ae05ddc3d053e1
BLAKE2b-256 a3e8261207d6cc7379d9491c0a0059599cbb3ae09a22d5c21b769931e3368e4f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page