Thursday, October 12, 2023
Introduced blog. Confused about Eleventy frontmatter for dates.
Today I created the very beginnings of this blog, which is generated with the static site generator 11ty. I started from scratch with the help of 11ty.Recipes. I am creating it in preparation for my upcoming batch at the Recurse Center, so that it will be easy to keep a record of my time there from the very start.
Date Woes
I got very muddled down with trying to manage the dates of these log entries in a pleasant way. I learned some about date filters and computed data, but got too confused to really even understand if what I want is possible.
Currently, my front matter looks like this:
date: 2023-10-12 14:00:00-7
day: "2023-10-12"
eleventyComputed:
title: "2023-10-12"
- I have to manually enter a time and timezone so that 11ty won't think I'm talking about UTC instead of my home timezone.
- I created a custom data key
day
where I manually re-enter the date as a string. This is used for generating permalinks and the page title. - I don't write the date in
title
directly because I might want to change how the titles are generated in the future, but don't want the permalinks to change. - 11ty has a great variety of options for generating the date of a page, but I want a date option that is both stable under modification and can be retroactive (in case I forget to write a log for a day in time, but want to write it retrospectively).
This should be possible, right?
Task Ideas
This section is for tasks I want on my radar, but haven't committed to yet.
- Create a projects section
- Create an about
- Describe my web development approach for this blog
- Link to my craft/math site
- Publish this blog
- Write about my goals at RC
- Write a page for the event I want to facilitate