Repository navigation
docs(fix): Preserve indented Elixir reference examples - #375
Merged
Merged
Conversation
This was referenced Dec 5, 2026
tony
force-pushed
the
fix/indented-elixir-examples
branch
from
December 5, 2026 21:13
ac76287 to
b0b4ec5
Compare
This was referenced Dec 5, 2026
why: The reference adapter loses code block boundaries in valid indented ExDoc examples and renders the callback as prose. what: - Read top-level indented examples from the Markdown block tree. - Preserve blank lines, relative indentation and IEx output. - Keep list and paragraph continuations in the surrounding prose.
why: Shared previews render the committed API model. The 0.1.3 model still put indented callbacks in prose after the adapter learned to extract them. Its owned-server example had no language or highlighting. what: - Regenerate the Elixir model from the same 0.1.3 source and toolchain. - Check the public reference export for the complete owned-server callback, its language, blank line and nested indentation.
why: Checking the language and the ends of the callback let a missing session creation pass. Both released indented code and the newer fenced form have a complete example in the pinned source. what: - Read the documented block from the source paired with the API model. - Compare the exported language and every code line with that block.
tony
force-pushed
the
fix/indented-elixir-examples
branch
from
December 6, 2026 00:21
c911dee to
917418a
Compare
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #371.
What changed, and why
The Elixir reference split an indented example at its blank line and rendered the callback as a paragraph. The adapter now reads top-level indented blocks from the Markdown syntax tree and passes each block to the existing code renderer. Readers can copy the alias, blank line and indented callback together from published docstrings.
IEx prompts and expected output stay in the same example. Paragraph and list continuations stay in the surrounding text. The companion PR adds an explicit Elixir fence to the source docstring. Source change
The branch builds on the released guide data in #368 and regenerates the shared site’s cached API model from the same Elixir 0.1.3 source. The rebuilt preview preserves the Server, Control, Pane, Session and Window examples as copyable code. Release source
Checks run
LibTmux.Server.with_owned/2docstring through the Astro reference page. The baseline had no highlighted block. The fixed page has one Elixir block with each source line and its indentation intact.Public site
The Elixir port builds its production reference with the renderer pinned in its caller. The adapter reaches that reference after the port adopts a docs revision containing this change. The explicit source fence in the companion Elixir PR also works on the older renderer. Elixir publisher update · Current production provenance
Rebased checks
After rebasing, the released API model passed its freshness check and the shared-site build rendered the owned-server callback with its blank line, indentation and syntax colors. The Elixir and Markdown adapter suites and the reference export passed in the same 89.314 s run. Pagefind and the assembled multi-site checks were outside this run.
Merge stack
This PR targets
mainat the bottom of the stack. Stack #399 · Changes in this PRAll seven documentation jobs passed, including preview publication on
917418af1. GitHub records the stack merge at5a6dc108d. CI run · Merged commit Local checks rebuilt the site on22947ee66after #398, #379 and #383 merged. They verified version selection, the Elixir documentation workflow, the showcase links and the rendered example.Published preview check
The published
Server.with_owned/2example matched all six lines of the released Elixir source, including its blank line and callback indentation. It rendered with 6 syntax styles. The guide and recording checks also passed. The served-page checks took 2.94 s after publication for917418af1. Rendered example · Publisher run On all 7 checked pages, the only difference from the CI artifact was the analytics script added by Cloudflare.Tool use
Codex updated the adapter and its tests and compared the native example data. A separate Codex reviewer checked the rendered HTML against the original and fenced source.