Repository navigation
Keep code inside tabs as Markdown in agent-facing pages - #4196
Merged
Merged
Conversation
Hugo renders the body of a {{% %}} shortcode to HTML whenever it's
nested inside another shortcode, before the inner template runs.
Every {{% tab %}} sits inside {{< tabs >}}, so the .md copy of each
tabbed page got HTML-escaped <pre> blocks instead of fenced code.
Call tab with {{< >}} instead, so its body reaches the template as
Markdown, and have tab.html render that Markdown with RenderString.
The rendered HTML is unchanged apart from whitespace between
elements and the pages' updated dates. In the .md copies of the six
tabbed pages, 112 HTML <pre> blocks become fenced code and 182
escaped entities go away.
Refs DOCS-258
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
✅ Deploy Preview for ornate-narwhal-088216 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
SharpRake
approved these changes
Oct 13, 2026
This branch was successfully 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.
Summary
Code inside tabs reached the agent-facing
.mdcopy of each page as HTML-escaped<pre>blocks instead of fenced code, so agents got"and<where commands have"and<. #4193 fixed this for every other shortcode. Tabs need a notation change, which the docs team approved in DOCS-258.Why the notation changes
Hugo renders the body of a
{{% %}}shortcode to HTML whenever it's nested inside another shortcode, before the inner template runs. Every{{% tab %}}sits inside{{< tabs >}}, so notab.mdtemplate could ever receive Markdown.Changes
tabcalls on six pages switch from{{% tab %}}to{{< tab >}}. That's five Libraries pages andcontainers/building-and-modifying/adding-packages.md.layouts/shortcodes/tab.htmlrenders the panel's Markdown itself with.Page.RenderString.layouts/shortcodes/tab.mddrops the comment describing the old limitation.Testing
Compared a full local build of
mainwith a build of this branch:main..mdcopies of the six pages: 112 HTML<pre>blocks become fenced code blocks, and 182 escaped entities are gone. Onlibraries/java/migration, 29<pre>blocks and 139 entities become clean fenced code.llms-full.txtis unchanged, because it renders shortcodes with their HTML templates.After merge
The wiki's Shortcodes page still tells writers to use
{{% tab %}}. A wiki edit is ready that switches its example and rules to{{< tab >}}. It also adds a step to "How to add a new shortcode": create a.mdtemplate beside the.htmlone. It goes live after this merges, since the new notation only renders correctly oncetab.htmlchanges.🤖 Generated with Claude Code