--- layout: default pagination: data: books.years size: 1 alias: year permalink: "/books/years/{{ year.value }}.html" schema: books-year --- {%- assign bookData = year.data | bookStatus: 'finished' | bookSortDescending -%} {%- assign bookDataFavorites = bookData | bookFavorites -%} {%- capture favoriteBooks -%}{{ bookDataFavorites | shuffleArray | mediaLinks: "book", 5 }}{%- endcapture -%} {%- capture currentYear -%}{% currentYear %}{%- endcapture -%} {%- assign yearString = year.value | append: '' -%} {%- assign currentYearString = currentYear | append: '' -%} {% tablericon "arrow-left" "Go back to the books index page" %} Back to books
I've finished {{ bookData.size }} books this year. Among my favorites are {{ favoriteBooks }}.
{% else %}I finished {{ bookData.size }} books in {{ year.value }}. Among my favorites were {{ favoriteBooks }}.
{% endif %}