Hi, I’m Francesco. Here I’ll collect projects where I defused the IF strategy, and share workshops that explore how these projects evolved.
if (condition) { doSomething(); } else { doSomethingElse(); }
It works. Problem solved.
But the problem isn’t today. It’s tomorrow.
IFs make change easy—once. Add enough IFs, and suddenly change isn’t so easy anymore. Nested conditions pile up, logic tangles, and the cost of change skyrockets.
IFs seem innocent, but they hide a deeper problem: they make your software harder to grow.
IFs are sneaky.
At first, they feel like control. One small condition here, another there. But soon, your code resists you.
Nested IFs don’t scale—they collapse. You try to follow the flow, but duplication hides bugs. Every new feature fights back.
What once felt simple now feels fragile. IFs start as helpers but end as chaos.
If you’re here, you probably fall into one of these categories:
Whoever you are, welcome.
This isn’t about "no IFs ever."
It’s about this: if I can handle change without an IF, my code will be simpler and easier to grow.
For example, in the Diamond Kata I developed:
grep -rw 'if' . | wc -l 0
Result? Zero. No IFs.
But the ultimate goal is to reduce the cost of change.
Reducing the number of IFs to zero is merely a consequence.
Try it: run the command in your project folder:
grep -rw 'if' . | wc -l
Do you use IFs as sparingly as you think? Or have they crept in quietly?
Over the years, I’ve learned this: developers love IFs.
Challenging IFs feels personal.
This site isn’t here to convince you. If you want to use IFs, go ahead. I prefer not.
Here, you’ll find:
Talking about avoiding IFs is easy. Doing it is harder.
Instead of debating, I focus on projects. Real code. Real results.
Polymorphism, maps, design patterns—there are many ways to replace IFs.
I’ve used a systematic method since 2005 to avoid IFs. It’s not magic, just a different way of thinking.
I’ll share that method soon, but this site isn’t about one approach. It’s about showing what’s possible.
Because seeing is believing.