chore: update examples and Readme

This commit is contained in:
relikd
2022-08-03 08:17:26 +02:00
parent 8e250fb665
commit e67489ab0b
5 changed files with 27 additions and 17 deletions

View File

@@ -2,8 +2,7 @@
<p>This is: {{this}}</p>
<p>Custom field date: {{this.date}}</p>
<ul>
{%- for child, extras in this.children.items() -%}
{%- set etxra = (extras|first).tags_in_page %}
<li>{{etxra|length}} tags on page "{{child.path}}": {{etxra}}</li>
{%- for child in this.children %}
<li>page "{{child.path}}" with tags: {{child.tags}}</li>
{%- endfor %}
</ul>

View File

@@ -20,7 +20,7 @@ main { margin: 3em; }
<footer>
{%- for k, v in [('testA','Config'),('testB','Simple'),('testC','Advanced')] %}
<div>{{v}} Tags:
{%- for x in this|vgroups(k, recursive=True)|unique|sort %}
{%- for x in this|vgroups(k, recursive=True, order_by='group') %}
<a href="{{ x|url }}">({{x.key}})</a>
{%- endfor %}
</div>