HN user

grose

1,642 karma

backend dev @ tokyo github.com/guregu

email greg at toki.waseda.jp

Posts4
Comments234
View on HN

It's also ignoring the fact that much plagiarized code is already under permissive licenses. If Star Wars or Daft Punk were CC-BY-SA nobody would need to pirate them, and there may even be a vibrant remix culture... which is kind of the whole point of open source, is it not?

[dead] 2 years ago

RTO usually seems like an indirect way to do some layoffs to me. Surely management must be aware of the attrition it causes.

I can only imagine how frustrating it is for the average user when they click on an "unhydrated" button that does nothing. JS frameworks embracing SSR is definitely a step in the right direction compared to the fully client-side apps of the previous hype cycle, and yet in many cases can still present worse UX than PHP sites of yore.

It's great to hear new people are interested in the language! I was enlightened a couple years ago and fell in love.

Currently I'm focusing on creating easy-to-use embeddings of Trealla Prolog using Wasm. You can find my TypeScript library here: https://github.com/guregu/trealla-js and Go library here: https://github.com/trealla-prolog/go. The goal is to make the libraries as painless as possible. Trealla is a portable and lightweight Prolog written in C that supports CLP(Z) and is broadly compatible with Scryer. It's quite fast! I'm currently using it for some expert system stuff at $work and as an internet forum embedded scripting language for $fun.

Speaking of Scryer, they recently got their WebAssembly build working and I hope to contribute a JS library for them in the future as their API stabilizes. Scryer and Trealla are both aiming for ISO compatibility, so it's my hope that we can foster an ecosystem for modern ISO Prolog and provide more embeddings in the future. It's super convenient to get logic programmer superpowers in your favorite language. Also check out Scryer's new website: https://www.scryer.pl/

For something on the silly side, check out https://php.energy. Prolog Home Page, it's web scale :-). It's proof that you can integrate Prolog with bleeding edge stuff like Spin (server-side wasm ecosystem).

My 4th and 5th grade teachers tricked us into learning algebra by calling it "enigmas" and treating it like a fun puzzle instead of a math problem. It definitely worked on me, I was quite shocked when middle school math was just those puzzles under a different name. Made those classes quite easy though.

<samp>, <var>, <kbd> are definitely weird ones. Maybe <kbd> would be more useful with some better default styling. I think <output> has some accessibility wins but I've never seen someone use it. <dfn> is a good pick, <abbr> is also up there with questionable semantic tags. <del> and <ins> are basically tailor-made for rendering diffs. <ruby> is really useful for Japanese, doing that styling manually would be a huge pain, but niche for sure. I'm happily surprised <small> survived. I still miss <center>.

Agreed that sewing is "technical". Imagine you're an artisan seamster and your clueless boss (zero sewing experience) says stuff like "go faster, it's just putting the needle in the hole isn't it?" or "can't you just tape this part together to meet the sprint deadline and do the sewing stuff later?".

I use the standard library html/template package for generating CSS dynamically, it's got pretty good CSS support. I've found it useful for things like custom themes and UI preferences.

Webpage looks great. Love the simple design with code examples front and center. I don't think it's fair to call the pricing transparent but hide it behind a sales gate. API looks nice, maybe a public page with API documentation would help. npm package is lightweight which is refreshing to see. Backend seems to be Cloudflare R2.

It's not as intense as regular dryer lint. Seems to be like small bits of thread that fall off during the drying process (perhaps coming off during tumble wash and sticking to it while wet?). There's a pretty strong gust of air coming from the dryer. My unit came with panels fitted for the bathtub and instructions to use when drying, it's a bath/shower combo thing.

Haha, I know exactly how you feel. I too often wondered about the optimal timing for clothes reinsertion... at least the dryer unit is pretty good at drying out the shower which seems to help with mold, so even if you're not using it for clothes it still serves a purpose.

To add on to this: I think they are mostly intended as an "emergency backup" for people who usually hang dry their clothes outside to use when it's raining, etc. If you're not using it as your primary drying method maybe it's not so bad? Having more than one shower probably helps too. Unfortunately I am not blessed with such a large space, and my balcony is pitifully small :)

I have one of these in my home (in Tokyo). Honestly... they kind of suck. The lint from your clothes clogs your drains and vents even faster than normal (you're supposed to use a plastic slab cover thing over your bath, which requires a lot of maintenance or it gets gross very quickly). It renders your shower unusable for hours at time, so if you live with other people it makes coordination of laundry/showers much more complex. Would not recommend. I got a regular washer/dryer combo unit recently and it markedly improved the quality of my life.

Aha, so it is part of the spec. Thanks for clarifying that. Appreciate the advice on discoverable credentials as well! I was probably leaving out the discoverable creds from the allowlist. Getting the timing down for when to ask for credentials was a bit tricky but I think I see the whole picture now.

I will say though, when it all works out it's a really nice way to log in, and my users are happy about it.

Very thorough article, nice! I'll add some other pain points I experienced:

- You need to let users register more than 1 passkey, but how to show them which is which? There are lists like this one[1] and FIDO provides a (maybe irrelevant?) list on their site[2] stuck inside of a JWT. I ended up using that JSON list + registration date + browser UA that registered it + "currently using" indicator when the current session derives from that specific passkey. Still kind of feels like a mess.

- The popular libraries seem to follow a kind of "shadow spec" where they agreed on using the URL-friendly variant of base64, which doesn't have native browser support. Not a big deal (just a couple helper functions needed) but kind of confusing if you're trying to implement the client or server bits from scratch. [Edit: as explained by a reply below, this is part of the actual spec!]

- I still don't know whether it's possible to use both usernameless and usernameful passkeys simultaneously. The APIs seem to be mutually exclusive, differentiated by some options (some of which are already deprecated?) and requiring empty lists to be passed in certain places. I'm trying to bolt on passkeys to a pre-existing auth flow and all I want is the closest thing to "use the browser's built in password manager". Ended up giving up on resident keys for now.

[1] https://github.com/passkeydeveloper/passkey-authenticator-aa...

[2] https://fidoalliance.org/metadata/