Skip to content

2024

Easy way to add Cover Image in Material for MkDocs Blogs

Image showing a monitor with a blog open Image created by OpenAI's DALL·E

Incorporating a figure with a caption in markdown can be cumbersome, especially if you're aiming for specific styling. Directly adding an image with a caption through raw HTML requires extensive boilerplate for each image, which isn't ideal for every cover image in your content.

Here's how I used Attribute Lists (1) markdown extension to streamline the process.

  1. Attribute Lists extension allows you to add HTML attributes and CSS classes to markdown elements. You can enable it in your mkdocs.yml file by adding the following configuration:
    markdown_extensions:
      - attr_list
    

Why habit apps suck, or do they?

Image showing a path with lot of turns Image created by OpenAI's DALL·E

I started using a habit-tracking app to keep my goals in check, and it was going great for the first five weeks. Then, I decided to tweak my strategy, thinking it would enhance my productivity. Fast forward three weeks, and I haven't opened the app since.

So, what exactly went south? Here's a quick dive into my experience.