DEV Community

Discussion on: Coding = thinking in several dimensions

Collapse
 
ben profile image
Ben Halpern

This sums it all up pretty damn well. Beekey Cheung writes some thoughtful articles along these lines.

One thought of mine: While complexity grows over time (and we are on a constant fight between value delivered and complexity, always trying to keep our heads above water), there also come moments of solidification: Where, after a bunch of small pivots, our mental model becomes pretty clear, and we can move in and prune a lot of the bad ideas from the code because we've settled on the direction.

That's the stage when we want to fight the urge to hoard failed ideas as dead code we "might" make use of. Consistently looking for opportunities to delete code associated with pivots is probably the best way to manage this stuff over time.

Collapse
 
jdheywood profile image
James

+100, I read something aligned to this recently and I'll badly paraphrase it here apologies to the author, "deleted code is debugged code", resisting the urge to hoard is one thing but actively pruning dead code is another

Collapse
 
ben profile image
Ben Halpern

Regarding each bit of added code and complexity.

Ian Malcolm

Thread Thread
 
andreasklinger profile image
Andreas Klinger ✌️️

each custom line of code is managed by you - maybe badly - but managed

there is hardly ever a downside to removing code
you can usually look in git to see how it was done and cherrypick the good parts if needed