Programming

Posts in Programming

Browse this space's posts and add your own text, images, videos, GIFs, or audio.

Back to space

Posts

4 posts

Putting the boat on a diet

New on the blog: a logged-out thread page went from 843 KB to 468. The interesting cut was lazy-loading the entire WebRTC call system behind a signed-in gate; the embarrassing one was three 923×1352 PNGs rendering at 40 pixels. Found along the way: a favicon that had been quietly 404ing for months, and gzip files nobody was serving.

https://jva.lol/weblog/putting-the-boat-on-a-diet/

8 days ago by jake

Awesome!

7 days ago by jake

Did you use any tools to figure that out or was it just through spelunking?

5 days ago by robzombie

Mostly spelunking, plus asking the obvious-in-hindsight question: do logged-out visitors really need WebRTC?

5 days ago by jake

The panel that closed itself

New on the blog: the composer's "Also show in" panel snapped shut every time you typed a letter.

A <details> element held its own open state, the server knew nothing about it, and LiveView's DOM patcher faithfully deleted whatever the server couldn't see. The patcher did it — and it still wasn't wrong.

https://jva.lol/weblog/the-panel-that-closed-itself/

It's the sequel to The panel that hid itself, where the patcher was the obvious suspect and came back innocent. Two panel bugs, opposite verdicts, same custody rule: every bit of state needs exactly one owner.

(Fitting footnote: this thread was filed using the picker the post is about — the fixed one.)

9 days ago by jake

Popsicle Boat as a comment section

I wrote up how jva.lol uses threads aboard as its comment section: the blog post links to a thread here, and that's the whole integration. No widget, no iframe, no tracker — a reader who wants the discussion follows the link, and the blog page itself stays static.

https://jva.lol/weblog/popsicle-boat-as-a-comment-section/

There's also a small Hugo trick in the post: the build probes each linked thread and drops the link if the thread stops answering, so deleted discussions don't leave dead ends.

This thread is that post's comment section.

10 days ago by jake

I do a similar thing with Mastodon on my digital garden: https://travisbriggs.com/garden/comments-research/

Except that I use the Mastodon server at mastodon.online for outsourcing the moderation capabilities and such. I've found that the silence wasn't because I had no comment system...

8 days ago by audiodude

Thought you'd like to know your reply ended up on jva.lol too — printed into the page, right under the post it discusses. Your comments research, out in the wild.

8 days ago by jake

In which I fix a bug with PopsicleBoat

I wrote up the story of a bug where a video call connected perfectly and its panel hid itself anyway: https://jva.lol/weblog/the-panel-that-hid-itself/ — the LiveView/DOM-patching rabbit hole was deeper than expected.

12 days ago by jake