Why You Should Sometimes Reinvent the Wheel

Picture this: You’re knee-deep in a project, caffeine coursing through your veins, when suddenly you need to implement a feature that surely someone has built before. Your colleague leans over and whispers those magic words that every developer has heard a thousand times: “Don’t reinvent the wheel.” But here’s the thing – sometimes that wheel is square, sometimes it’s made of concrete, and sometimes it comes with 47 dependencies that’ll make your bundle size explode faster than your patience during a code review....

August 11, 2025 · 8 min · 1549 words · Maxim Zhirnov

Почему вам иногда следует изобретать велосипед

Представьте: вы по уши в проекте, в венах бурлит кофеин, и вдруг вам нужно реализовать функцию, которую наверняка кто-то уже создавал. Ваш коллега наклоняется и шепчет те волшебные слова, которые каждый разработчик слышал тысячу раз: «Не изобретай колесо заново». Но вот в чём дело: иногда это колесо квадратное, иногда оно сделано из бетона, а иногда у него 47 зависимостей, которые увеличат размер вашего бандла быстрее, чем ваше терпение во время ревью кода....

August 11, 2025 · 6 min · 1142 words · Maxim Zhirnov
The Case Against Code Reuse: When Writing from Scratch is Better

The Case Against Code Reuse: When Writing from Scratch is Better

We’ve all been there - staring at a 10-year-old utility class that’s become the Frankenstein’s monster of your codebase. “But it’s reusable!” your teammate insists, as you discover it now contains 47 optional parameters and a hardcoded reference to IE6. Let’s explore when writing fresh code might save your sanity (and your stack). The Hidden Costs of Reuse 1. The Overgeneralization Trap Reusable code often starts with good intentions: // The "Swiss Army Knife" string processor function processText( input: string, options: { trim?...

May 27, 2025 · 3 min · 513 words · Maxim Zhirnov
Аргументы против повторного использования кода: Лучше писать с нуля

Аргументы против повторного использования кода: Лучше писать с нуля

Мы все бывали в такой ситуации — смотрели на утилитный класс десятилетней давности, который стал монстром Франкенштейна в вашей кодовой базе. «Но он же переиспользуемый!» — настаивает ваш коллега, пока вы обнаруживаете, что теперь в нём 47 необязательных параметров и жёсткая привязка к IE6. Давайте разберёмся, когда написание нового кода может спасти ваше душевное равновесие (и стек). Скрытые затраты на переиспользование 1. Ловушка чрезмерной обобщённости Переиспользуемый код часто начинается с благих намерений:...

May 27, 2025 · 3 min · 523 words · Maxim Zhirnov
The Fallacy of 'Code Reuse at All Costs': When Duplication is Better

The Fallacy of 'Code Reuse at All Costs': When Duplication is Better

The Allure and the Pitfall of Code Reuse In the world of software development, the concept of code reuse has long been touted as a holy grail. The idea is simple: write once, use everywhere. It sounds like a dream come true—less code to write, fewer bugs to fix, and faster development cycles. However, this dream often turns into a nightmare, and it’s time to confront the fallacy of “code reuse at all costs....

September 15, 2024 · 5 min · 871 words · Maxim Zhirnov