section

discussion

Wire value: "discussion"

Not emitted on any page (see notes above).

1. How swift-docc-render consumes this

This page documents a kind value that, as far as the pinned commits show, is declared but never actually emitted by current swift-docc, and would be rejected by current swift-docc-render if it ever appeared. That negative finding is itself the useful fact here, so this section explains how it was established rather than pointing to a component that renders it.

RenderSectionKind lists discussion as one of several "Symbol render sections" alongside content:

public enum RenderSectionKind: String, Codable {
    // Article render sections
    case hero, intro, tasks, assessments, volume, contentAndMedia, contentAndMediaGroup, callToAction, tile, articleBody, resources

    // Symbol render sections
    case mentions, discussion, content, taskGroup, relationships, declarations, parameters, sampleDownload, row
    ...
}

(RenderSection.swift#L15-L20, the pinned swiftCaseSite.) The section that actually produces a symbol's "Discussion"/ "Overview" prose is DiscussionSectionTranslator, and it hardcodes the emitted kind to .content, not .discussion:

return ContentRenderSection(kind: .content, content: discussionContent.capitalizingFirstWord(), heading: title)

(DiscussionSectionTranslator.swift#L45.) git log -p --follow on that file shows every historical revision of this line has always written kind: .content; a full-history git log -S"kind: .discussion" search across swift-docc found zero commits that ever constructed a render section with kind: .discussion. The decoder side keeps .discussion alive purely for backward-compatible reading: CodableContentSection's kind switch maps both .discussion and .content to the same ContentRenderSection type —

switch kind {
    case .discussion:
        section = try ContentRenderSection(from: decoder)
    case .content:
        section = try ContentRenderSection(from: decoder)
    ...
}

(Sources/SwiftDocC/Model/Rendering/RenderNode/CodableContentSection.swift#L41-L45) — so discussion reads as a legacy/reserved alias for the exact same payload shape as content, kept so that older archives (if any ever used it) still decode, while every current encoder writes content instead.

On the render side, a grep of src/components/ and src/views/ for the literal string "discussion" in swift-docc-render turns up exactly one hit, and it is unrelated to this RenderSectionKind case: a named Vue <slot name="discussion"> in ContentTableSection.vue#L23-L27, filled in by TopicsTable.vue#L32-L34 from a Topics task group's own discussion field (the wire type TasksGroupSection.discussion, itself typed as a ContentRenderSection — see Section 3). That is a same-named but structurally different concept: a task group's optional intro blurb, not the page-level Discussion/Overview section this page is about.

The actual page-level Discussion/Overview content — whatever kind value it carries — is dispatched by PrimaryContent.vue, which validates every incoming section's kind against a hardcoded SectionKind lookup object (src/constants/PrimaryContentSection.js) that has no discussion entry at all — only content:

export const SectionKind = {
  attributes: 'attributes',
  content: 'content',
  declarations: 'declarations',
  mentions: 'mentions',
  details: 'details',
  parameters: 'parameters',
  possibleValues: 'possibleValues',
  properties: 'properties',
  restBody: 'restBody',
  restCookies: 'restCookies',
  restEndpoint: 'restEndpoint',
  restHeaders: 'restHeaders',
  restParameters: 'restParameters',
  restResponses: 'restResponses',
};

(PrimaryContentSection.js#L12-L27.) PrimaryContent.vue's sections prop carries a validator that runs this exact check against every section before rendering:

sections: {
  type: Array,
  required: true,
  validator: sections => sections.every(({ kind }) => (
    Object.prototype.hasOwnProperty.call(SectionKind, kind)
  )),
},

(PrimaryContent.vue#L55-L62.) A section with kind: "discussion" would fail hasOwnProperty.call(SectionKind, 'discussion') (it is not a key of that object), triggering a Vue prop-validation warning, and then componentFor(section)'s own lookup table (PrimaryContent.vue#L74-L90, which is likewise keyed only by SectionKind.content, never a discussion key) would resolve to undefined, rendering nothing for that section. In short: the render layer is built to handle content, and has no branch reserved for discussion — consistent with the production translator never emitting it.

2. Example JSON and rendered mockup

No fixture anywhere searched contains the literal JSON "kind": "discussion". A grep of Tests/DocCArchiveTests/Fixtures/ (both ExampleDocs.doccarchive and SampleLibrary.doccarchive) for "kind": "discussion" found zero hits in any render-node JSON (the only fixture hits for the bare string discussion are inside those archives' bundled, minified documentation-topic.048469da.js runtime script — swift-docc-render's own compiled JS, not RenderNode data). A grep of swift-docc's own Tests/SwiftDocCTests/ for the same literal also found zero hits. This is expected, given Section 1's finding that no current code path emits this kind value.

What DocCArchive's fixtures do contain, in real archive data, is the sibling kind: "content" shape — the exact same ContentRenderSection payload structure that discussion would have used, straight from Tests/DocCArchiveTests/Fixtures/ExampleDocs.doccarchive/data/documentation/exampledocs/examplearticle.json:

{
  "kind": "content",
  "content": [
    { "type": "heading", "level": 2, "text": "Overview", "anchor": "Overview" },
    {
      "type": "paragraph",
      "inlineContent": [
        { "type": "text", "text": "Description of what the article is about - the problem being solved, etc." }
      ]
    },
    { "type": "codeListing", "syntax": "swift", "code": ["func main() {", "    print(\"hello world\")", "}"] },
    { "type": "heading", "level": 3, "text": "Section header", "anchor": "Section-header" },
    {
      "type": "paragraph",
      "inlineContent": [
        { "type": "text", "text": "Details, step by step, or explanations grouped by section headers." }
      ]
    }
  ]
}

That fixture is real but, per Section 1, uses "content", not "discussion", as its kind value — because that is what current swift-docc actually writes. To show the exact shape kind: "discussion" would take if a decoder chose to honor it (per CodableContentSection's decode-time alias, Section 1), here is a minimal synthetic example:

{
  "kind": "discussion",
  "content": [
    { "type": "heading", "level": 2, "text": "Discussion", "anchor": "discussion" },
    {
      "type": "paragraph",
      "inlineContent": [
        { "type": "text", "text": "Further detail about this symbol, beyond the one-line abstract." }
      ]
    }
  ]
}
Discussion

Further detail about this symbol, beyond the one-line abstract.

mockup: were this reached by PrimaryContent.vue, it would render exactly like a content section — plain flowing prose from ContentNode.vue, no discussion-specific chrome. In current swift-docc-render, per Section 1, a section literally tagged "discussion" instead fails the SectionKind validator and renders nothing.

3. Data sheet

Source: Sources/DocCArchive/Vendored/RenderNode.spec.json, schema object #/components/schemas/ContentRenderSection (lines 2717–2735), cross-checked against Components.Schemas.ContentRenderSection in Sources/DocCArchive/generated/Types.swift (lines 6274–6300). No DiscussionRenderSection or similarly-named type exists anywhere in the vendored spec or the generated types — the vendored schema only ever declares a ContentRenderSection, and its kind field is constrained to a single literal value.

FieldTypeRequiredEnum values / defaultNote
kind string yes "content" (single-value enum) — "discussion" is not a legal value in the vendored schema Vendored JSON Schema: "kind": { "type": "string", "enum": ["content"] }. Generated Swift: KindPayload: String, Codable, Hashable, Sendable, CaseIterable { case content = "content" } — a frozen, single-case enum. A DocCArchive consumer decoding a hypothetical archive whose JSON literally contains "kind": "discussion" would fail to decode that value into Components.Schemas.ContentRenderSection.KindPayload, because OpenAPI Generator only emitted the one case actually present in the vendored spec. This is a real gap relative to swift-docc's own RenderSectionKind Swift enum (Section 1), which still declares .discussion as a valid (if unused) case for decode-time compatibility.
content array of RenderBlockContent yes — Arbitrary block-level content (headings, paragraphs, code listings, asides, etc.) — the parsed Markdown of the symbol's Discussion/Overview doc comment or an article's body prose. Matches swift-docc's own ContentRenderSection.content: [RenderBlockContent] (Sources/SwiftDocC/Model/Rendering/Symbol/ContentRenderSection.swift#L16).

Related but distinct field: TasksGroupSection.discussion (vendored spec lines 2736–2767; generated Types.swift lines 6301–6342) is a property named discussion, typed as an optional ContentRenderSection, attached to a Topics task group. It is not a RenderSectionKind discriminator value; it is the wire counterpart to the <slot name="discussion"> usage found in Section 1's TopicsTable.vue/ ContentTableSection.vue trail, and it is out of scope for this page's kind: discussion subject.

4. HTML/CSS mapping in DocC-Render output

Because current swift-docc never emits kind: "discussion" (Section 1) and the vendored schema does not even allow that literal to decode (Section 3), there is no DOM/CSS mapping to document for a section actually tagged that way — there is nothing in the render tree keyed on the string "discussion" as a RenderSectionKind.

What does exist, and what a symbol's Discussion/Overview prose actually renders as today (under kind: "content"), is documented on the sibling content/articleBody pages of this reference: PrimaryContent.vue mounts a bare PrimaryContent/ContentNode.vue for a content-kind section, which itself is a thin passthrough (DocumentationTopic/ContentNode.vue#L11-L26) to the shared block/inline renderer src/components/ContentNode.vue, which turns each RenderBlockContent item into ordinary heading/paragraph/code-listing HTML with no discussion-specific wrapper element, id, or CSS class of its own — spacing between sections comes from PrimaryContent.vue's own scoped style block (PrimaryContent.vue#L132-L155), via the $section-spacing-single-side SCSS variable and the CSS custom property --colors-grid (falling back to --color-grid) used for the optional top border.

DocCArchive transform status: not yet implemented. MyHTMLTransformer and MyMarkdownTransformer in Sources/DocCArchive/DocCArchive.swift are still stub placeholders — the HTML transformer returns a hardcoded <!-- what? --> comment regardless of input, and the Markdown transformer returns an empty string — so there is no code today that would notice or act on either the content/discussion kind ambiguity described above.

5. Modern CSS-only alternative

NOT APPLICABLE

Current behavior in play: there is no current behavior to describe, because no live code path in the pinned commits ever produces or consumes a render section literally tagged kind: "discussion" (Section 1). The nearest real behavior — PrimaryContent.vue's kind-keyed component lookup for the content section that actually carries this prose — is, like the articleBody case documented elsewhere in this reference, a one-time, non-interactive template-render dispatch: a static object lookup performed once per section at mount time, with no click handler, no v-show/v-if toggle, and no later state change. There is consequently no interactive/stateful behavior anywhere in this kind's story to replace with <details>/<summary>, radio+:checked, :target, the Popover API, <dialog>, :has(), container queries, CSS anchor positioning, or view-transitions. The honest, concrete reason this verdict is "not applicable" rather than merely "no interactivity": the kind itself is effectively dead wire syntax in current tooling — a reserved decode-time alias with no emitter and no matching consumer branch — so there is no shipped behavior at all to translate to CSS, modern or otherwise.