--- title: Eric's Journal path: /journal/index.html --- <% const MAX_POSTS = 6; -%> <% const cwd = (process && process.cwd) ? process.cwd() : ''; -%> <% const titleLink = (site && site.base_uri) ? site.base_uri : '/'; -%> <%- include('../../layouts/partials/top') %>
<%- include('../../layouts/partials/embed_switch') %> <%- include('../../layouts/functions') %> <% if (page?.title && (page?.render_opts || '').indexOf('no_title') == -1) { -%>

<%= page.title %>

Below you'll find some of my most recent Journal entries.


<% } -%> <% if (site && site.pages) { -%> <% let curr_post_num = 0, pages = site.pages.sort((a, b) => { if (a.date_pub && b.date_pub) { let a_dt = (new Date(a.date_pub)).getTime(), b_dt = (new Date(b.date_pub)).getTime(); if (a_dt < b_dt) { return 1; } if (b_dt < a_dt) { return -1; } return 0; } }); -%> <% pages.forEach(function(page) { -%> <% if (page.content_type && page.content_type === 'journal' && curr_post_num < MAX_POSTS) { -%> <% curr_post_num++; -%>

<% if (page.author && page.author.site && page.author.name) { %> <% if (page.author.photo) { %> <% } %> <% } else if (site.author && site.author.site && site.author.name) { %> <% if (site.author.photo) { %> <% } %> <% } %>

<%= page.title %>

<% if (page.tldr || page.description) { -%>

TL;DR — <%- page.tldr || page.description %>

<% } -%> <% if (page.readTime) { -%>

👓 <%= page.readTime %>

<% } -%> <% if (page.content) { -%>
<%- page.content %>
<% } -%>
<% if (Array.isArray(page?.tags) && page.tags.length) { -%>
📁 <% page.tags.forEach((tag, index) => { -%> <%= tag %><%= (index < (page.tags.length - 1)) ? ', ' : '' %> <% }) -%>
<% } -%>

<% } -%> <% }); -%> <% } -%>

All Entries By Year

    <% if (site && site.pages) { let years = []; site.pages.forEach(function(page) { if (page.content_type && page.content_type === 'journal' && page.date_pub) { let the_year = (new Date(page.date_pub)).getFullYear(); if (years.indexOf(the_year) === -1) { years.push(the_year); } } }); years = years.sort().reverse(); years.forEach((year) => { -%>
  • <%= year %>
  • <% }) } -%>
<%- include('../../layouts/partials/journal/menusub') %> <%- include('../../layouts/partials/bio') %> <%- include('../../layouts/partials/footer') %>
<%- include('../../layouts/partials/bottom') %>