Skip to main content

No project description provided

Project description

Starfyre ⭐🔥

Introduction:

Starfyre is a library that allows you to build reactive frontends using only Python. It is built using pyodide and wasm, which enables it to run natively in the browser. With Starfyre, you can create interactive, real-time applications with minimal effort. Simply define your frontend as a collection of observables and reactive functions, and let Starfyre handle the rest.

Please note that Starfyre is still very naive and may be buggy, as it was developed in just five days. However, it is under active development and we welcome contributions to improve it. Whether you are a seasoned web developer or new to frontend development, we hope that you will find Starfyre to be a useful tool. Its intuitive API and simple, declarative style make it easy to get started, and its powerful features allow you to build sophisticated applications.

Installation:

The easiest way to get started is to clone create-starfyre-app repo. Hosted at create-starfyre-app

Sample Usage

src/init.py

from starfyre import create_component, render

from .component import Component


def main():
    component = Component()
    render(create_component(<component></component>))

src/component.py

from starfyre import create_component, create_signal

[get_component_state, set_state] = create_signal(0)


def updateCounter(component, *args):
    set_state(get_component_state(component) + 1)


def Component():
    return create_component("""<div onClick=updateCounter>
        This is the component state
        <button>Click Here to increment</button> {get_component_state}
        </div>""",
    )

Developing Locally

  1. make in-dev

For more flexibility, see make help

Feedback

Feel free to open an issue and let me know what you think of it.

Project details


Download files

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

Source Distribution

starfyre-0.4.2.tar.gz (6.3 MB view details)

Uploaded Source

Built Distribution

starfyre-0.4.2-cp310-cp310-macosx_11_0_arm64.whl (174.4 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file starfyre-0.4.2.tar.gz.

File metadata

  • Download URL: starfyre-0.4.2.tar.gz
  • Upload date:
  • Size: 6.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/0.14.10

File hashes

Hashes for starfyre-0.4.2.tar.gz
Algorithm Hash digest
SHA256 2af4dd6a77689697796eff53fb9c77ed32acec6ee483976ee2ea08a316db892c
MD5 973ebbcde0571f8ff65db5bd3600dad6
BLAKE2b-256 2234e52e1b6a4330b3e630294584ebe173cce423e5b6099b5d8448f5ddd0ca97

See more details on using hashes here.

File details

Details for the file starfyre-0.4.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for starfyre-0.4.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 fcefeaf1f874df412f44022b9564c8d9ff011a95d642a92f23b14171ef5dedcc
MD5 2e4d2b48427c9ab9f1da7fb171754344
BLAKE2b-256 e5ec6a3d427d5a0b56163a955a19aea9680d46a3fb979750c966ccfb6f40aafc

See more details on using hashes here.

Supported by

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