← Back to context

Comment by skrowl

3 years ago

I have the opposite feeling about them. I think they make the code more readable.

Yes, done well it adds that benefit and if the extension method is universal to the type then proceed ahead with some caution. LINQ is a great example of this.

Where it falls apart is when it turns out that slightly different behavior is needed based on sub-type.

The right thing is to then move past the extension method, but it's more compelling to take the short-term gains of bolting-on more logic into the extension method.