lyall

Joined 11 years ago

Karma
269
Submissions
69
Member since
Jan 22
https://lyall.co
View on Hacker News

Recent submissions

Comment · 14 days ago
"Hanako, my lovely wife, should we settle down and have kids?"

"I want nothing more than to raise a family, but alas I simply can't face brining a child into a world in which people applying for citizenship in this country have to present such a long list of documents."

"I feel the same way, honey."

Comment · 1 month ago
I'm surprised that articles like this that are pretty clearly AI-generated get any sort of traction here. Is it because people think the topic is interesting but don't actually care about the content?

> Three Japanese words, three Hepburn transcriptions. The letters you already know, telling you what they sound like.

I mean come on.

Comment · 2 months ago
> Go to restaurant

> Order food

> Food comes out as raw, unprepared ingredients

> Complain to chef

> Tells me to go cook it myself

> wtf, I'm not here to do work for free

> "Is doing something for yourself really working for free?"

Comment · 3 months ago
There might be something valuable in this article, but if the you couldn't be bothered to write it yourself, why should we be bothered to read it?
Comment · 3 months ago
Good call. I've updated to release script to always include the SRI hash in the README sample.
Comment · 3 months ago
Comment · 3 months ago
Comment · 3 months ago
It should be when the screen width is less than 456 css px with the current configuration.
Comment · 3 months ago
Thankfully the unit it operates on is a paragraph, not the whole body of text. Also thankfully computers are very fast these days!

I added the “Alice in Wonderland (long)” text sample to the demo as a stress test, but its paragraphs are still relatively short. I should add a sample that’s one really long paragraph and see what happens. I may need to add a bail-out after X items option if it calls for it.

Comment · 3 months ago
The layout is done entirely in DOM. The layout engine calculates the line breaks, tracking, expansion, etc. then applies the layout using HTML spans with the appropriate attributes applied. There’s generally one span per line, but that can change for more complicated lines! I invite you to inspect the demo page in your browser’s dev console if you’re particularly curious.

And yes, I did use LLMs for the implementation, both Fable 5 and 5.6 Sol specifically. I would not have been able to achieve anywhere close to the current result unaided. My patience and expertise would’ve been exhausted long before getting anywhere especially interesting.

My philosophy with LLMs is to try to use them to achieve levels of quality and polish that would’ve been previously unreasonable. I hope this project is a demonstration of that.

Comment · 3 months ago
That's not something justif supports directly right now. It currently targets rectangular blocks, not arbitrary edge shapes. But the underlying line-breaking approach could accommodate per-line widths, so it would be plausible to add I think.

Feel free to make a GitHub issue with details and I can take a look at supporting it. For now the workaround would be falling back to native justification by excluding the paragraph from justif, and using css float/shape-outside to get the desired edge.

Comment · 3 months ago
It is the default if you open the demo on a narrow screen! It has a more striking difference between browser and justif layouts at narrow widths than the Alice sample. But maybe you’re right and it should be the default for everyone.
Comment · 3 months ago
Hyphenation: yes, justif does its own hyphenation. It ships with TeX’s hyphenation dictionaries for a bunch of languages, but supports custom dictionaries as well! See https://github.com/lyallcooper/justif#hyphenation

Narrow columns: open up the controls on the demo and try adjusting the width slider :)

Long documents: try the “Alice in Wonderland (long)” sample text in the demo to get a feel for how it handles long documents. In general it performs well enough I think, though Safari is a little slower than other platforms. It doesn’t do it incrementally (not sure that’s possible), but I spent quite a while trying to make sure it was fast enough to re-layout in real time even on long documents.

I haven’t thought about coexisting. I’m not sure how that could work but I’m open to ideas.

Comment · 3 months ago
Yes, there is something to be said for this argument. Debit card and cash users pay slightly higher prices than they might otherwise, which do subsidize the rewards of credit card users. But this is distinct from the argument presented in the article, which is that poor people's credit card debt funds rich people's airline miles.

But there factors that counteract this. Merchants pay different average fees depending on the mix of cards that they accept. A dollar store probably sees fewer Chase Sapphire Reserved or Amex Platinum cards than a Gucci store does. Accordingly, the average interchange fee they pay is probably lower. [0]

Also fee surcharging is becoming more common in the US these days, and is already common is some other countries. Visa et al. still don't allow merchants to pass on the actual interchange they'll pay, but merchants can charge a fee to credit card transactions that they don't on debit or cash.

But my original point is that giving rich people credit card rewards are not a transfer from the poor to the rich. It's a rational business decision by card companies that does not require any outside funding source, from poor people or otherwise, to make work financially.

0: There are some other factors that complicate this, such as the risk profile of the business. Riskier generally means higher fees.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton