Extract includes for links, tags and related posts
This commit is contained in:
parent
5baae90010
commit
e70d8c6f1f
4 changed files with 38 additions and 30 deletions
13
source/_includes/notes/related.html.twig
Normal file
13
source/_includes/notes/related.html.twig
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
{% if related and notes %}
|
||||
<section>
|
||||
<h2>Related</h2>
|
||||
|
||||
<ul>
|
||||
{% for note in notes if related|filter((title) => title == note.title) %}
|
||||
<li>
|
||||
<a href="{{ note.url|trim('/', 'right') }}">{{ note.title }}</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</section>
|
||||
{% endif %}
|
||||
Loading…
Add table
Add a link
Reference in a new issue