Metadata-Version: 2.4
Name: astris
Version: 0.1.0
Summary: Minimal Python framework for building static websites with component-style APIs.
License-Expression: MIT
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: fastapi>=0.129.0
Requires-Dist: uvicorn>=0.41.0
Dynamic: license-file

# Astris

[![Tests](https://github.com/fmanzano/pystro/actions/workflows/tests.yml/badge.svg)](https://github.com/fmanzano/pystro/actions/workflows/tests.yml)

Astris is a minimal Python framework for building static websites using component-style APIs.

## Installation

```bash
pip install astris
```

## Quick start with CLI

Create a new project scaffold:

```bash
astris new my_site
cd my_site
uv run python main.py
```

Build static files:

```bash
uv run python main.py build
```

## Basic usage

```python
from astris import AstrisApp
from astris.lib import Body, H1, Html

app = AstrisApp()


@app.page("/")
def home():
	return Html(children=[
		Body(children=[
			H1(children=["Hello from Astris"]),
		])
	])


if __name__ == "__main__":
	app.run_dev()
```

## Development

```bash
uv sync --group dev
uv pip install -e .
uv run --group dev pytest
```

## Continuous Integration

GitHub Actions runs tests on push and pull request events targeting main using Python 3.11, 3.12, and 3.13.
The workflow is defined in `.github/workflows/tests.yml`.

## Release checklist

```bash
make release-check
```

Equivalent manual commands:

```bash
uv sync --group dev
uv run --group dev pytest
uv run --group dev python -m build
uv run --group dev twine check dist/*.whl dist/*.tar.gz
```

`example.py` in this repository is an internal framework demo and not the standard end-user workflow.
