Metadata-Version: 2.4
Name: remotestate
Version: 0.1.0
Summary: Python state, React UI.
Project-URL: Homepage, https://github.com/bcdev/remotestate
Project-URL: Issues, https://github.com/bcdev/remotestate/issues
Project-URL: Repository, https://github.com/bcdev/remotestate
Author: forman
License: MIT
License-File: LICENSE
Keywords: jupyter,python,react,state,ui
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.12
Requires-Dist: fastapi<0.137,>=0.136
Requires-Dist: pydantic<3,>=2
Requires-Dist: uvicorn<0.47,>=0.46
Description-Content-Type: text/markdown

# RemoteState - Python

`remotestate` is the Python runtime for the _RemoteState_ library.

It gives you:

- `Store` for application state
- `Service` for defining actions and queries
- `action` and `query` decorators
- `serve()` for exposing the backend to the React frontend

## Install

```bash
pip install remotestate
```

## Quick Start

```python
import remotestate as rs

store = rs.Store({"count": 0})


class MyService(rs.Service):
    @rs.action
    async def increment(self):
        self.store.set("count", self.store.get("count") + 1)


rs.serve(MyService(store), dist_dir="my-ui/dist")
```

For the full project overview, see the repository root README:
[Remote State](https://github.com/bcdev/remotestate)
