With annotated, declarative step-based YAML integration tests. They autogenerate how-to markdown documents via a jinja2 template:
https://github.com/hitchdev/hitchstory (there are a few toy examples listed there)
Depending on the app the docs might also embed artefacts generated under test - e.g. screenshots from playwright.