Running Eleventy's Dev Server in Production
currently, this website is being served from a multiplexer running npx @11ty/eleventy --serve --port XXXX. this has some benefits (instant reload, primarily,) but also some challenges.
Image Plugin
do not use Eleventy’s Image plugin for this usecase. it is not worth it. you can either set it up in one of two ways:
-
have it transform images on request
- this is bad because it is a lot of load on your server. the plugin does not seem to cache the results, and it will result in your images taking longer than usual to load (and your poor server being hammered with imagemagick calls).
-
have it pre-transform every image on load
- this is bad because every time you make a change to your website, it will re-run all images. this means it can take, like, a minute each time. this is noticeable and blocks incoming requests.
there is properly a better way to do this. maybe a third party plugin. i would like to be able to jpegxl my images, and stuff like that. but manually resizing important images (e.g. logos) and inlining them with data:base64 is good enough for me (for now.)