Jekyll: Post Loop in Liquid Templates

Posted in Notes on 17 October 2019

Jekyll uses the Liquid templating language to process templates. This post provides a basic example to show the five latest blog posts and highlight the first post.

The code consists of two loops, the first loop shows one post (the newest one) the second post shows the next four posts.

Related Notes Posts

February 2024

Animated SVGs (Scalable Vector Graphics)

Animated SVGs, Scalable Vector Graphics, are increasingly popular choices for adding dynamic elements to websites. Their scalability, lightweight nature, and flexibility make them attractive options... Continue reading

December 2023

Using Scalable Vector Graphics (SVGs)

Scalable Vector Graphics (SVGs) have revolutionised website design, offering unparalleled flexibility, scalability, and interactivity. As versatile graphic elements, SVGs can enhance the visual appeal and... Continue reading

September 2023

Designing websites for accessibility

In the ever-evolving landscape of web design, the balancing act between accessibility and aesthetic appeal remains a crucial consideration. As the digital realm becomes increasingly... Continue reading

More Notes Posts