refactor: rename _partials to _includes

This commit is contained in:
Oliver Davies 2022-01-03 10:26:51 +00:00
parent 0482badc95
commit a445072048
17 changed files with 0 additions and 0 deletions

View file

@ -0,0 +1,15 @@
{% macro shouldDisplayOldPostMessage(post) %}
{% set cutOffDate = 'today -1 year'|date('U') %}
{% if post.date is not empty %}
{{ post.date <= cutOffDate }}
{% endif %}
{% endmacro %}
{% import _self as helpers %}
{% if helpers.shouldDisplayOldPostMessage(post)|trim %}
<div class="p-6 my-10 border border-gray-300 dark:bg-gray-800 dark:border-gray-700">
<p><strong>Warning:</strong> This post is over a year old. I don't always update old posts with new information, so some of this information may be out of date.</p>
</div>
{% endif %}