pub async fn test_simple_nested_document(
document: String,
settings: RenderSettings,
) -> Result<i32>Expand description
Test function demonstrating nested document runtime spawning via dependency-injected IPC.
In real use, the document runtime would send a request to the workspace to
spawn a sub-document process and pass the workspace the node ID to render
in a single start_document() (or something like that) call. The workspace
would then handle most interaction with the subprocess (including the final
render of multiple documents composed together), because the runtime for one
document shouldn’t have access to the runtimes for nested documents data or
state beyond the initial node ID or passed through secure message passing.
§Arguments
document- The document content to processipc- The IPC context for communicating with the workspace
§Returns
A formatted string combining the original document with the subprocess response.