The Bad Apple animation as ASCII art rendered in real-time from the server @ 60 FPS using htmx + sse extension + server-commands extension.
cp .env.example .env
docker compose up
The server-commands
extension provides a special <htmx>
tag. The server streams <htmx>
tags ~60 times/second via SSE to update multiple elements in real-time:
data: <htmx target="#frames" swap="textContent">{frame}</htmx>
data: <htmx target="#progress-text" swap="textContent">{progress}%</htmx>
You can read more about it in the extension's README.md.