Expand description
批量重建文章 HTML 与目录。
用于数据迁移或修复:遍历符合条件的文章,将 Markdown 重新渲染为 HTML,
并更新 content_html 与 toc_html 字段。
Leptos server function,注册在 /api 路径下。
仅在 feature = "server" 启用的服务端构建中执行数据库更新。
Structs§
- Rebuild
Content Html - Serialized arguments for the
rebuild_content_htmlserver function. - Rebuild
Post Content Html - Serialized arguments for the
rebuild_post_content_htmlserver function.
Constants§
- MAX_
DISPLAY_ 🔒ERRORS - 返回给前端展示的最大错误条数。
- REBUILD_
BATCH_ 🔒LIMIT - 单次重建批处理数量。每批 100 篇,保证单次调用在 30 s 请求超时内完成。
Functions§
- rebuild_
content_ html - 批量重建文章 content_html 与 toc_html(单批,客户端按游标续传)。
- rebuild_
post_ content_ html - 重新渲染指定文章的 content_html 与 toc_html。