Comment

Comment by nanodeath

I _think_ what they're saying is a specialized/curried function that takes a single argument is better than the method it's replacing that takes three strings or whatever. That is, `foo.a("a").b("b").c("c")` is better than `foo.a("a", "b", "c")`. Which...sure, but 1. if you're really passing 2-3 parameters in with identical types, maybe use inline value classes instead? Or at least type aliases?, and 2. if you can't or don't want to do that, named arguments help.
parent nanodeath 3 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton