Ronalds Vilciņš

Showing the word count in Jekyll

If you want to count word in a string, use number_of_words liquid filter.

<p>
{% assign wordCount = post.content | number_of_words %}
</p>

Enjoyed this post? Please grab the RSS feed. You can also buy me a coffee.