//! Root HTML document rendering.
pubmodclosure;pubmodminimal;pubmodvite;pubuseclosure::ClosureRootView;pubuseminimal::MinimalRootView;pubusevite::{ViteManifest, ViteRootView};usecrate::ssr::SsrPayload;/// Context passed to a `RootView` implementation.
pubstructRootViewContext<'a>{/// HTML-attribute-escaped page object JSON (safe to interpolate inside
/// `data-page=""`). Retained for views that emit the legacy div-attribute
/// form; the Inertia v3 client reads page data from a `<script>` tag, so
/// most views should prefer [`Self::page_json_script`].
pubpage_json:&'astr,
/// Script-tag-safe page object JSON (safe to interpolate inside
/// `<script ...>...</script>`). The only sequences mutated relative to
/// raw JSON are `</`, `<!--`, and `]]>` — the JSON value is otherwise
/// byte-for-byte preserved, so the client can `JSON.parse` it directly.
pubpage_json_script:&'astr,
/// Current asset version.
pubasset_version:&'astr,
/// Optional pre-rendered SSR chunks.
pubssr:Option<&'a SsrPayload>,
}/// Renders the initial HTML shell for a non-XHR response.
pubtraitRootView: Send + Sync {/// Produce the HTML body for the response.
fnrender(&self, ctx:RootViewContext<'_>)->Result<String, String>;}