Comment

Comment by natch

What is going on in the below line?

    c = [t v]
Can you tell me what c represents, and where it got its value? Sure, from [t v], but what are those? No, you can't. You finished reading it really quickly, but you understand very little about what is going on.

"A lot more text" is there for a reason: to explain what is going on.

How about:

    cellsToUpdate = [tableView visibleCells]
This code tells you exactly what each item means. I find clear naming really nice to work with. Not that I would necessarily use exactly that line as a way of doing things, but hopefully you get the idea.
parent natch 12 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton