Fix unresolved data lookups on GitHub Glossary page (#16815)
* Support [...] in data tag path * Use forloop.index0 to get data tag path * Commit whitespace change to not keep getting it * Recursively render glossary terms as well * Add tests to verify Liquid data tag can handle bracketed access * Remove superfluous 'set' for context in tests * Avoid the mystery guest anti-pattern... move the test data closer to the test * Escape the `-` character in the data regex Co-authored-by: Jason Etcovitch <jasonetco@github.com> Co-authored-by: Chiedo John <2156688+chiedo@users.noreply.github.com>
This commit is contained in:
@@ -10,8 +10,8 @@ versions:
|
||||
---
|
||||
|
||||
{% for term in site.data.glossaries.external %}
|
||||
### {{term.term}}
|
||||
{{term.description}}
|
||||
### {% data glossaries.external[forloop.index0].term %}
|
||||
{% data glossaries.external[forloop.index0].description %}
|
||||
---
|
||||
{% endfor %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user