Using images with ImageKit

Media on this blog lives on ImageKit, not in the repo. Upload an image via the ImageKit dashboard (or CLI), then reference the CDN URL directly in markdown:

![Alt text describing the image](https://ik.imagekit.io/YOUR_ID/example.jpg)

Resizing on the fly

ImageKit transforms images via URL parameters, so you can request an appropriately sized version instead of shipping the original. The content column here is 680px wide, so w-1360 (2x for retina) is a good default:

![Alt text](https://ik.imagekit.io/YOUR_ID/example.jpg?tr=w-1360)

Captions

For a captioned figure, drop into HTML — markdown allows it inline:

<figure>
  <img src="https://ik.imagekit.io/YOUR_ID/example.jpg?tr=w-1360" alt="Alt text" />
  <figcaption>The caption goes here.</figcaption>
</figure>

Video works the same way — upload to ImageKit and use a <video> tag with the CDN URL.