You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Variables example in creating-reusable-content uses tags that do not resolve #46875
The same example is also in data/variables/README.md.
What part(s) of the article would you like to see updated?
The variables example says the values in data/variables/foo/bar.yml are reachable as {% data foo.bar.meaning_of_life %} and {% data foo.bar.nested.values.too %}, but neither tag works if you copy it. getDataByDir in src/data-directory/lib/get-data.ts only reads variables when the path starts with variables., so both tags fail with "Can't find the key", and with the prefix added the nested one still fails because the last two segments are taken as the file and the key, so it looks for data/variables/foo/bar/nested/values.yml. The value also has to be a string, because a bare 42 is loaded as a number and gray-matter throws "expected input to be a string or buffer" on it.
So the example should quote '42', swap the nested block for a second top-level key, and show the tags as {% data variables.foo.bar.<key> %}, which is the form all the real tags in content/ and data/ use.
Additional information
I checked it by running the current getDataByDir against a foo/bar.yml fixture with the repo's js-yaml and gray-matter versions, where the documented tags fail and the fixed ones render 42 and Yes!. Claude Code helped me trace this through the code, and I'll open a PR with the fix.
@ZainnQureshii Thanks for raising an issue; you're right to highlight that some of this content does need updating, but we can't accept community contributions for it, so unfortunately I've closed your PR out and I'm going to mark this to fix internally, and take an action to refine some of the content as appropriate. Sorry this won't have been the outcome you were hoping for, but thank you for your interest in the GitHub docs. Please feel free to keep an eye out for issues marked help wanted.
Thank you for opening this issue! Updates to this documentation must be made internally. I have copied your issue to an internal issue, so I will close this issue.
Activity
subatoi commentedon Nov 9, 2026
@ZainnQureshii Thanks for raising an issue; you're right to highlight that some of this content does need updating, but we can't accept community contributions for it, so unfortunately I've closed your PR out and I'm going to mark this to fix internally, and take an action to refine some of the content as appropriate. Sorry this won't have been the outcome you were hoping for, but thank you for your interest in the GitHub docs. Please feel free to keep an eye out for issues marked
help wanted.docs-bot commentedon Nov 9, 2026
Thank you for opening this issue! Updates to this documentation must be made internally. I have copied your issue to an internal issue, so I will close this issue.
subatoi commentedon Nov 10, 2026
@ZainnQureshii Just to follow up, I fixed this internally and added you as a co-committer. You should see the commit visible within the next 24 hours