Skip to main content

43 posts by Cory Dransfeldt

Rebuilding your Netlify site at regular intervals

With my site on Netlify I've set up a function to rebuild it at regular intervals (hourly, in my case).

Dec 6, 2024

Categories: DeploymentHow to...

Here's how this is all put together

I've been fiddling with this site for the better part of a year now and now that it's fairly stable, I'm putting together what amounts to a public README (or a note to self). This post is that document.

Nov 8, 2024

Categories: CMSCollectionsData CascadeGlobal DataImagesSearch

Building an album releases calendar subscription

As part of tracking the music I listen to I also keep track of upcoming albums. When I add an album, I also have fields for release dates and links.

Oct 27, 2024

Categories: CollectionsDatesHow to...

11ty meetup: Tracking and displaying music history

I got to speak at the 11ty meetup today about the music tracking contraption I've built into my site. I have a fairly detailed post on how I built it and another on the method I'm using to render dynamic media (read: musician/band) pages.

Oct 23, 2024

Categories: Global DataHow to...YouTube

Dynamic pages with 11ty and Cloudflare workers

I was rendering about 3300 pages every time my 11ty site built — probably overkill. About 615 artist pages, 1200+ movie pages, 500 show pages, 500 for books and ~35 for genres. Whew. Build times hovered at about a minute (still very impressive!) but would only ever increase.

Oct 22, 2024

Categories: DeploymentHow to...Remote Data

Aggregating content using collections in Eleventy

I have a bunch (too much?) content on this site and I use a collection containing a few child functions to aggregate all of it into a sitemap, search index and unified feed that gets syndicated to Mastodon.

Oct 4, 2024

Categories: CollectionsHow to...RSS

Syndicating an RSS feed to Mastodon using a Cloudflare worker

Everything shared from my site to Mastodon runs out of a single all activity RSS feed. You're welcome to subscribe to it, but it's formatted with social syndication in mind — emojis, hashtags and truncation that match that use case. This feed is populated from a fairly verbose processContent collection. It also populates my sitemap and search index since there's plenty of overlap in format and the data being handled. Anyways.

Sep 22, 2024

Categories: CollectionsHow to...RSS

A feed for everything and everything in a feed

At the moment my site has 6 different feeds. 5 RSS feeds, an ICS feeds and JSON versions of the 5 RSS feeds. I was asked how they're put together and, well, it's a bit involved.

Aug 9, 2024

Categories: FiltersHow to...MarkdownRSS

It turns out a CMS can be pretty awesome

Having a CMS to update your site can be awesome. It's not strictly necessary and mine is entirely over-engineered but here we are. It's helpful on mobile, it's been incredibly useful on desktop.

Jul 18, 2024

Categories: CMSFront MatterHow to...Remote Data

Building out a books page

I had a ton of fun reading about how Melanie put together her reading page that I thought I'd write up a quick post on how I built mine.

Jul 3, 2024

Categories: Now PageHow to...Remote Data

Integrating a (somewhat) custom CMS with Eleventy

I've spent the last, uh, month or so inching my way towards leveraging a CMS to manage the content on this site. It started with improving my self-hosted scrobbling setup, importing yet more of my personal data and then looking around at friendlier options to manage what I'd spun up.

Jun 3, 2024

Categories: CMSCollectionsLayoutsRemote Data

Building pages from data in Eleventy

I've expanded the media sections I already had built to include pages generated from data using Eleventy.

May 24, 2024

Categories: Data CascadeHow to...Remote Data

Handling images with B2, Netlify's image CDN, Hazel and Mountain Duck

I've spent a while hosting and fetching images from bunny.net when my 11ty builds. I had multiple pull zones configured and wanted to leverage bunny.net's transforms, but the pricing of $15/month per zone wasn't feasible.

May 1, 2024

Categories: How to...Images

Enhancing pagination with a page selector

I've made a change to my site's pagination wherein I've enhanced the page count displayed at the bottom of my home and links pages to display the page count in a select element. The select displays a list of all the pages and navigates to the selected page.

Apr 5, 2024

Categories: How to...Pagination

Lightweight search in Eleventy

I've been using Pagefind for my site search for a while now and would readily recommend it, but I wanted to throw together something a bit lighter weight and customizable.

Mar 18, 2024

Categories: How to...Search

Using an Eleventy event to optimize component JavaScrip

I've added a small event to optimize web component JavaScript when my site builds.

Mar 10, 2024

Categories: Asset PipelinesHow to...Performance

Surfacing most used tags in Eleventy

I made some lightweight design changes to my site, keeping things simple but moving the date up above post headers, surfacing tags below and restoring Read more links.

Mar 9, 2024

Categories: CollectionsFiltersHow to...

Weaving music data in and out of my personal website

I started integrating music data into my personal website when I added Last.fm artist and album displays to my now page. Initially, I tried sourcing artist images from a few different services, knowing that Last.fm had updated their API to stop serving them. After a fair bit of searching I found that most services that supplied artist images covered only a small fraction of my library and often supplied the wrong image when there were multiple artists sharing the same name.

Feb 22, 2024

Categories: How to...Now PageRemote Data

Building a bespoke now-playing web component

I've long had a now playing element on the home page of my site that displays either what I've checked into on Trakt, the Lakers' record and who they're playing when a game is on or the last song I've listened to. After leveraging some new web components on my site, I decided to refactor the code powering this into a web component specific to my needs.

Feb 21, 2024

Categories: Remote DataHow to...Now Page

Automatic Mastodon post embeds

I use Nicolas Hoizey's GitHub action to syndicate my web activity to Mastodon. Recently, I removed the display of webmentions from my posts after seeing Chris and Robb discuss some privacy concerns around them. Upon seeing David Darnes' mastodon-post web component, I've gone ahead and added it, conditionally, to the end of each of my posts.

Feb 20, 2024

Categories: DeploymentSocial MediaWebmentions

Using B2 as a JSON data store

My links page is powered by the Readwise Reader API but because there are, quite reasonably, rate limits in place, I've gone ahead and reduced the page count I fetch on each build and cached older link data from past builds in a B2 bucket.

Feb 19, 2024

Categories: Data CascadeGlobal DataHow to...Remote Data

Setting up image transforms in Eleventy

Eleventy added a transform option to process images in Eleventy v3.0.0-alpha.5 and Image v4.0.1 so, naturally, I had to set it up on my site. If you don't want to read this post, you can check out the full diff for the changes.

Feb 14, 2024

Categories: How to...ImagesPlugins

Check if images are available before optimizing in Eleventy

How to check if a remote image is available before attempting to optimize it using @11ty/eleventy-img.

Feb 5, 2024

Categories: How to...ImagesWebmentions

How I use Readwise Reader to post and share links.

Jan 10, 2024

Categories: BloggingHow to...Remote Data

Programmatically importing your Last.fm listening data to ListenBrainz

I love Last.fm, but in the interest of redundancy, Ive started programmatically importing my listening data from Last.fm into ListenBrainz.

Dec 5, 2023

Categories: Data CascadeGlobal DataHow to...Remote Data

Hacking together a Tweekly.fm replacement

I mused the other day about wanting a replacement for Tweekly.fm which shut down due to Twitter's API changes and restrictions. In my case, the aim would be to make this compatible with Mastodon since that's where I've found myself spending the most time recently.

Nov 15, 2023

Categories: How to...Remote Data

Semi-automated hashtags for syndicated posts

I went out on a limb recently and decided to build a custom collection in Eleventy that aggregates my post tags and link tags (sourced from Matter). These tags then get appended to shared post or link titles when they're syndicated from my site.

Sep 10, 2023

Categories: CollectionsHow to...

Now page: grouping episodes of the same tv show

I made a minor update to how I'm normalizing TV data for display on my now page.

Sep 6, 2023

Categories: Remote DataHow to...Now Page

Drying up now page templates and normalizing data in Eleventy

My now page consists of a number of similar sections — some bespoke text, a number of media grids and lists. The text is repeated once, the lists are easily templated out in Liquid.js and the media grids are all quite similar.

Sep 3, 2023

Categories: How to...

Displaying now playing data with matching emoji using Netlify edge functions and Eleventy

My site is built using 11ty and is rebuilt once an hour. These frequent rebuilds accomplish a few things, notably updating webmention data and keeping my now page current.

Aug 25, 2023

Categories: How to...Edge FunctionsNow Page

I took some time last week to build out a popular posts widget after seeing Zach's implementation using Google Analytics.

Jul 12, 2023

Categories: Remote DataHow to...

Displaying listening data from Apple Music using MusicKit.js

Up until now my now page has sourced music data from Last.fm (and may well again). But, in the interest in experimenting a bit, I've tried my hand at rewriting that part of the page to leverage data from Apple Music, using MusicKit.js instead.

Jun 21, 2023

Categories: Remote DataHow to...

From ICS to JSON: surfacing anticipated albums

I use MusicHarbor by Marcos Tanaka to track upcoming albums from my favorite artists (typically by syncing my last.fm data with the app.) When I see something new that I want to add to my collection I throw it on a calendar creatively titled Albums.

Jun 8, 2023

Categories: Remote DataHow to...

Optimizing for performance with Eleventy

In the interest of over-engineering my personal site I've gone out of my way to optimize it for performance.

Jun 7, 2023

Categories: PerformanceHow to...

Now page update: favorite articles from Matter

I dropped in a quick update to my now page to display the 5 most recent articles from my favorites feed in Matter.

May 5, 2023

Categories: How to...

Another Eleventy content syndication path

After posting and discussing my post from yesterday with Nicolas Hoizey I decided to explore his suggested path and explore using a GitHub action to handle posts to Mastodon, rather than Make.

Mar 28, 2023

Categories: Social Media

Lazy select-based pagination in Eleventy

I've relaunched, rebuilt and rewritten my personal blog more times than I can count, and I've had a trail of posts I've never fully migrated at each turn. This weekend, while relaxing and watching movies I ported them into Eleventy and, in doing so, found that the pagination implementation I was using didn't scale well with the number of pages I added.

Mar 27, 2023

Categories: Pagination

Automate and syndicate content from Eleventy to Mastodon

I've discussed building a now page using Eleventy, but I also syndicate a subset of that content out to Mastodon using @11ty/eleventy-activity-feed and Make.

Mar 27, 2023

Categories: Social Media

.env files in Eleventy

The Eleventy docs recommend the dotenv package for working with .env files, but I've found dotenv-flow to be a bit more useful inasmuch as support for .env* file patterns make development more convenient.

Mar 24, 2023

Categories: How to...

Scheduled Eleventy builds on Vercel with cron-triggered GitHub actions

In an effort to get away from client-side Javascript and embrace Eleventy for what it is (a static site generator), I've dropped my social-utils instance offline and my now-playing track display on my home page that still relied on it.

Mar 19, 2023

Categories: DeploymentScheduling

Building my /now page using Eleventy

As part of my commitment to writing about things I've written in other frameworks in Eleventy, this is how I re-engineered my /now page in Eleventy.

Mar 18, 2023

Categories: Remote DataNow Page

Webmentions in Eleventy

In the interest of continuing to repeat myself I'm writing, once again, about adding webmentions to a blog.

Mar 17, 2023

Categories: Webmentions

Get the blog by email (or RSS)

Powered by Buttondown