pub struct Fragment {
pub concept: Concept,
pub key: &'static str,
pub variant: Variant,
pub depth: Depth,
pub locale: &'static str,
pub audience: Option<Audience>,
pub rank: u8,
pub title: Option<&'static str>,
pub body: &'static str,
}Expand description
A unit of content, addressed by (concept, key, variant, locale).
Fields§
§concept: ConceptConcept this fragment belongs to.
key: &'static strSub-topic within the concept, e.g. "no-word-splitting".
variant: VariantHow this fragment renders its idea.
depth: DepthSummary fragments always show; Reference only at reference depth.
locale: &'static strBCP-47 locale tag. English ("en") is the canonical-complete base.
audience: Option<Audience>None = shared (default); Some(_) = audience-specific divergence.
rank: u8Importance rank for the always-on onboarding block: 0 is the most
important, and composition renders fragments in ascending rank so the
client model meets the critical rules first even under skimming or
truncation. Fragments at UNRANKED (the default) keep registry order.
The rank is a property of the (concept, key, variant) slot, so it is
locale-agnostic — a translation of a fragment inherits the same rank.
title: Option<&'static str>Optional section heading for reference rendering (e.g. "Quoting").
None for inline fragments (the Foundations spine renders under its
concept header instead). Used by render_syntax_reference.
body: &'static strMarkdown body.