DEV Community

Discussion on: Do you recognize your code 6 months later?

Collapse
 
fluffy profile image
fluffy

I generally recognize my code but often think, "Wow, what was I thinking?"

As I get older I also find myself frequently thinking, "Dang, my code could use [random feature], I'm gonna start designing it" and then just as I start writing code to do it I discover... I already did that months ago. And documented it fully.

Collapse
 
mortoray profile image
edA‑qa mort‑ora‑y

Ah yes, the classic redundant rewrite. I believe I've done that a few times as well. I think it speaks towards making sure your refactoring is fully complete, which involves removing the original code you were replacing -- ensuring it is never seen again.

Collapse
 
fluffy profile image
fluffy

Not even a rewrite, but attempting to write something the first time before realizing I'd already done it. :) Apparently past-me is very good at predicting present-me's needs.