User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
Admin
Wyvern-shaped software developer and hobby vector artist. Also sometimes a fluffy werewolf alien creature (Areon).

Creator of the neofoxes, neocats and other emojis.
wvrnBox
Website
https://volpeon.ink/
Speaking German, English
Age 30s
Pronouns he / him
Backup Account @volpeon@goto.wyvern.rip
Bonus Content @areon@icy.wyvern.rip
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
4w
I finally solved the last big problem with my SSG: handling page data. The way it works now is that you tell Corvos in the config what data pages can have, and if you choose a field as type discriminator, you can easily get the full page data by just doing e.g. page.data.type === "art-item". This way, I don't even have to list all the fields a template accepts, just the type is enough. areonNHappy
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
4w
Something fills up my RAM and causes programs to crash and refuse to start even way before its actually full. Icons in the Gnome UI disappear as well. Super annoying
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@Johann150 I knew the risks neofox_googly_woozy
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
github.com/oven-sh/bun/pull/33864

robobun (bot): "@robobun, your PR has 5 CI failures"
Claude (bot): "LGTM"

neofox_googly_woozy
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
Flat goat areonNFlat
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@stefan @puniko EEEEEEEEEEEEEEEEEEEE areonVScream
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
I started using streams for heavy pages (i.e. images). Without cache, my site builds in 60s. Lume takes 157s. Granted, I haven't added emoji sprites yet, but I do generate PNG files in addition to WebP and AVIF which wasn't the case before.

With cache, Corvos writes files so fast the terminal swallows the log entries.
neofox_googly_woozy
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
It makes sense once you identify the logical groups
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
SASS now gets a custom asset() function to get hashed URLs and generally just check if a referenced asset actually exists.

Also, look at that motherfucker of a config (now with two
hash() stages as well because I need to hash the CSS after the SASS compilation neofox_googly_woozy )
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
How am I supposed to debug a problem when said problem doesn't happen in the debug version aaaaaaaaaaa areonNScream
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
I love working with WeakRefs for caching, they work fine in dev, but in production items are evicted and I have no fucking idea why
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@ziphi areonVMug
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@riki I think Canva's Affinity is good as a free software, but risky if you want to rely on it in the long run. Compared to V2, it has improved the UI and I like that you don't have to deal with separate programs anymore. The non-destructive path operations are also pretty damn good.

However, I noticed that features that used to work fine would suddenly be broken after an update, and stay this way for several weeks. I heavily rely on some of these in my workflow, so that sucked a lot.
I once stuck with an older version, which worked. With a later update, I noticed the bugs and got too annoyed with them only after I'd already invested a lot of work, and I found I couldn't go back to an older version because Affinity had marked the file as incompatible. That was the point it completely lost my trust.
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@blackratbighat @nikitonsky That's what I strongly suspect is going on here, yes. neofox_googly_shocked
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@errant areonNAngel
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
If you noticed two uses of jsx(), good job! This is completely correct because template() re-introduces JSX into the pipeline which needs to be turned into HTML again. It was actually way more confusing to allow JSX as input to templates, feeds and sitemaps because then there wasn't a guarantee you'd get the final URLs.
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
The configuration is wild, but that's what you get for maximum flexibility
const pipeline = Pipeline.create()
	.use(fscache())
	.use(query())
	.use(modules<Page<".html", string> | Page<".tsx", JSX.Children> | Page<".strapi", Node[]>>())
	.use(
		sass({
			loadPaths: [
				"submodules",
				"submodules/iro-design/src",
				"submodules/iro-sass/src",
				"submodules/include-media/dist",
			],
		}),
	)
	.use(mdx())
	.use(markdown())
	.use(strapi())
	.use(jsx())
	.use(timestamps())
	.use(urls({ base: "https://volpeon.ink/" }))
	.use(feeds())
	.use(sitemap())
	.use(assets())
	.use(hash())
	.redirect("pages root", (page) => page.url.replace(/^\/pages\//, "/"))
	.redirect("scripts+styles assets", (page) =>
		page.url.replace(/^\/(scripts|styles)\//, "/assets/"),
	)
	.use(templates())
	.use(jsx())
	.use(icons())
	.use(
		images({
			allowedOrigins: ["strapi.volpeon.ink"],
			defaults: { formats: ["avif", "webp", "png"], densities: [1, 2] },
		}),
	)
	.use(transformImages());

const site = new Site(pipeline, {});
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
There are 2 hashes in the image URLs in the last screenshot because one of it is already included by Strapi in the filename. areonNMlem
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
I finally got asset caching to work in a way that the hashed URLs are available to templates
User avatar
privTri Volpeon areonNSmol @volpeon@icy.wyvern.rip
1mo
@nikitonsky It's even worse, the SVG exists purely to handle the text selection, and what's displayed on top of it is a dynamically generated raster graphic put into an img tag. That's also why there's the weird copy-paste discrepancy, because both don't line up. This is amazing, it's like they had a challenge to implement this in the most complicated and unreliable way possible. neofox_googly_shocked