The main use for refactoring is not to improve bad code, but to reduce/eliminate redundant code.
Redundant code is often the result of copy-paste reuse (the worst kind of reuse), for very short-term gains. Instead of functional abstraction, code is copy-pasted and slightly changed, building up technical debt that can slow development to a crawl, often 10 times slower or worse.
Yup, I totally agree. I have seen that kind of technical debt, a project of ours which was done in a copy-paste way without much thought, ended up with a tech-debt so big it would've taken us 2.5-3 years to remove. This project was 1 year old at the time
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
The main use for refactoring is not to improve bad code, but to reduce/eliminate redundant code.
Redundant code is often the result of copy-paste reuse (the worst kind of reuse), for very short-term gains. Instead of functional abstraction, code is copy-pasted and slightly changed, building up technical debt that can slow development to a crawl, often 10 times slower or worse.
Yup, I totally agree. I have seen that kind of technical debt, a project of ours which was done in a copy-paste way without much thought, ended up with a tech-debt so big it would've taken us 2.5-3 years to remove. This project was 1 year old at the time