diff options
| author | 魏曹先生 <1992414357@qq.com> | 2026-07-11 16:03:20 +0800 |
|---|---|---|
| committer | 魏曹先生 <1992414357@qq.com> | 2026-07-11 16:03:20 +0800 |
| commit | 810536fb1f068f969af316be0450a1edacfe8e28 (patch) | |
| tree | ece6a67f196afda364d4443e17687c2076e132c4 /docs/pages/13-hook.md | |
| parent | 4bf23c20f2d7cdfcc988b654a93abae1cd211ad8 (diff) | |
docs: migrate renderers from `r_println!` to `RenderResult` return type
Diffstat (limited to 'docs/pages/13-hook.md')
| -rw-r--r-- | docs/pages/13-hook.md | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/docs/pages/13-hook.md b/docs/pages/13-hook.md index 0c5e460..26f8712 100644 --- a/docs/pages/13-hook.md +++ b/docs/pages/13-hook.md @@ -60,7 +60,7 @@ Each hook callback receives a corresponding `Hook*Info` struct containing contex @@@#[chain] fn handle_greet(args: EntryGreet) -> Next { @@@ ResultName::new(args.inner.first().cloned().unwrap_or_default()).to_render() @@@} -@@@#[renderer] fn render_name(r: ResultName) { r_println!("Hello, {}!", *r); } +@@@#[renderer] fn render_name(r: ResultName) -> RenderResult { RenderResult::new() } fn main() { let mut program = ThisProgram::new(); |
