Comment

Comment by kidmenot

14 levels of indentation across 811 lines. Wow indeed.

I refactor as soon as my code gets past 3 levels, I don't know how one is supposed to readily understand this block of code.

The lack of comments isn't what troubles me. Comments get old and, when they do, they get completely misleading and downright dangerous. As soon as you feel the need to add a comment, it's often because that particular chunk of code should be extracted into its own function/method/whatever and given an intelligent name. Comments should be reserved for really important stuff, like when the code does something totally non-obvious.

parent kidmenot 10 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton