Skip to content

Proa documentation AGENTS.md changelog

io.github.proa-web/docs

1 change recorded. MCP Harbor re-reads this listing from the official registry every six hours and asks the live server what it exposes, and keeps what changed between one look and the next.

  • AGENTS.md +40 −11

    https://raw.githubusercontent.com/proa-labs/proa/HEAD/AGENTS.md

    − Application sync components normally implement `WebRenderSync<L>`. The full− trait definition is:− Async-capable components normally implement `WebRender<L>`. The full trait− definition is:− Use `WebRenderSync` by default. Use `WebRender` only for components that need to `.await`.− # {self.title}− {self.body}− "###− The token composition form (`md_sync! { "# " { title } }`) remains supported− for generated code and cases that need the expressions visible as Rust tokens.− cargo run -p proa_marketing+ Application sync components normally implement `WebRenderSync<L>`. Its body+ method signature is:+ Async-capable components normally implement `WebRender<L>`. Its body method+ signature is:+ Use `WebRenderSync` by default. Use `WebRender` when the body or metadata hook+ needs to `.await`. Async head hooks use native+ `async fn render_head(&self, cx: &mut WebContext<L>) -> Result<(), WriteError>`.+ Declare `const ROLE: ComponentRole = ComponentRole::PAGE` on the selected Page,+ including inherited-only Pages; ancestor metadata providers declare `LAYOUT`.+ Run `cargo proa lint <changed-paths> --deny warnings` to catch head overrides+ with missing roles or an explicit `COMPONENT` role. Async role validation is a+ source check; sync hooks also retain a code-generation assertion.+     # {self.title}+     {self.body}+     "###+ Single-literal templates select their mode at render time: physically multiline+ raw literals are block scopes, while ordinary strings and single-line raw+ literals are inline scopes. Hash count has no effect. Scopes restore the+ enclosing mode on errors, unwinding, and async cancellation; block boundaries+ are completed only before the body and after success. Authored whitespace and+ partial output remain, except that the line breaks after a slot at block+ position are boundaries, so a block child on its own line gains no extra blank+ line. Block templates cannot appear inside inline scopes,+ link labels, headings, emphasis, or table cells. Use `.render_md(cx)?` directly,+ without manual inline-mode restoration. Do not restore whole `MdState`+ snapshots solely for formatting cleanup, since that also replaces suffix+ tracking while partial output remains. Audit scaffold+ copies and fixtures when migrating these patterns.+ Text outside slots is always Markdown; each `{ ... }` slot is Rust. Use+ ordinary Rust `if`, `for`, and `match` there, and re-enter Markdown through a+ nested macro. Prefer ordinary one-line strings for short fragments, such as+ `md_sync! { "- {item}\n" }` and `md_sync! { "**In stock**" }`. Preserve the+ row-ending `\n`. Use raw templates for substantial multiline fragments, with+ fewer hashes inside an outer raw literal. Never remove the explicit slot boundary around control flow.+ See [the Markdown skill](.agents/skills/proa-markdown/SKILL.md) for a complete+ loop/branch example and the exceptions for code fences and exact separators.+ The body is always one string literal; token composition such as+ `md_sync! { "# " { title } }` is a compile error. To render values in sequence+ without authoring Markdown, use a tuple: `(overview, impact).render_md(cx)`.+ cargo proa run -p proa_marketing --bin proa_marketing