feat: MDX rendering support — backend content_type + content_raw fields #66

Closed
mik-tf wants to merge 1 commit from development_mdx_support into development
Owner

Summary

  • Add content_type ("html" or "mdx") and content_raw (raw source for MDX files) to PageDetail RPC response
  • Detect .mdx file extension in get_page handler and include raw content
  • Regenerate schema docs, SDK types, JS types from updated OSchema
  • Fix fmt/clippy issues from code generation

This is the backend half of MDX support. The frontend rendering lives in hero_archipelagos.

## Summary - Add `content_type` ("html" or "mdx") and `content_raw` (raw source for MDX files) to `PageDetail` RPC response - Detect `.mdx` file extension in `get_page` handler and include raw content - Regenerate schema docs, SDK types, JS types from updated OSchema - Fix fmt/clippy issues from code generation This is the **backend half** of MDX support. The frontend rendering lives in hero_archipelagos. ## Related - [hero_archipelagos #29](https://forge.ourworld.tf/lhumina_code/hero_archipelagos/issues/29) — MDX rendering in books island (frontend) - [hero_books #44](https://forge.ourworld.tf/lhumina_code/hero_books/issues/44) — original MDX issue (closed, moved to archipelagos)
feat: add content_type and content_raw fields to PageDetail for MDX support
Some checks failed
Test / test (pull_request) Failing after 2s
Test / integration (pull_request) Has been skipped
7067f38bbc
The get_page RPC response now includes:
- content_type: "html" for regular markdown, "mdx" for MDX files
- content_raw: raw source content (only present for MDX files)

This enables the WASM frontend to detect MDX pages and render JSX
components client-side instead of relying on server-side HTML that
strips JSX.

Also regenerates schema docs, SDK types, and fixes fmt/clippy issues
from code generation.

Related: lhumina_code/hero_archipelagos#29

Co-Authored-By: mik-tf <mik@threefold.io>
mik-tf changed title from WIP: feat: MDX rendering support — backend content_type + content_raw fields to feat: MDX rendering support — backend content_type + content_raw fields 2026-02-26 04:23:44 +00:00
mik-tf closed this pull request 2026-03-01 15:06:19 +00:00
Author
Owner

Superseded by PR #73. MDX support tracked in issue #70.

Superseded by PR #73. MDX support tracked in issue #70.
Some checks failed
Test / test (pull_request) Failing after 2s
Test / integration (pull_request) Has been skipped

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lhumina_code/hero_books!66
No description provided.