Skip to main content

Minimal Python framework for building static websites with component-style APIs.

Project description

Astris

Tests

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

Installation

pip install astris

Quick start with CLI

Create a new project scaffold:

astris new my_site
cd my_site
uv run python main.py

Build static files:

uv run python main.py build

Basic usage

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

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

make release-check

Equivalent manual commands:

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.

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

astris-0.1.1.tar.gz (8.6 kB view details)

Uploaded Source

Built Distribution

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

astris-0.1.1-py3-none-any.whl (7.5 kB view details)

Uploaded Python 3

File details

Details for the file astris-0.1.1.tar.gz.

File metadata

  • Download URL: astris-0.1.1.tar.gz
  • Upload date:
  • Size: 8.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for astris-0.1.1.tar.gz
Algorithm Hash digest
SHA256 04aa7c783fa7254a5321ec3dfa8bb89ac6bd766ecaf52df517a1eb3921d1d864
MD5 781a691abfe76d938131de9545f330e9
BLAKE2b-256 b62ad8deba553c293486a965f4784779c06370bfdbe307c5220703f79837b933

See more details on using hashes here.

File details

Details for the file astris-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: astris-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 7.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for astris-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f41ea0a12b2359054b5f9a69e120c96b9f75baed81ff30c5c8a42c7bc81fa8b2
MD5 6b736299346ea2a1365b0228a28bbb54
BLAKE2b-256 41228f68270ccff445a0217b6cbb8b695df02d5e81ea2c8e68a3cd77c7c802d6

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 Pingdom Monitoring Sentry Error logging StatusPage Status page