← Atpakaļ

Jekyll reading time without plugins

This script calculates the reading time based on a configurable reading speed (180 words per minutes by default).

<p>
  {% assign words = content | number_of_words %}
  {% if words < 360 %}
    1 min
  {% else %}
    {{ words | divided_by:180 }} mins
  {% endif %}
  read
</p>

Piesakies jaunumiem

Pievienojies abonentiem un saņem jaunāko saturu no manis tieši savā e-pastā. Nekāda spama. Tikai noderīgs saturs.