5-interface-pollution/ #92
Replies: 6 comments 2 replies
-
|
This was quite helpful, thank you |
Beta Was this translation helpful? Give feedback.
-
|
Nice explanation, thanks 👍 |
Beta Was this translation helpful? Give feedback.
-
|
Excellent👍 |
Beta Was this translation helpful? Give feedback.
-
|
Thank you for your book. I bought the physical version, but I still feel that the e-book version is more convenient (for computer technology books), especially when it comes to the source code part. I hope that the entire book has a complete electronic version. |
Beta Was this translation helpful? Give feedback.
-
|
Cool! |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for the explanation—it's really helpful. However, I'd love to see some concrete examples of what you consider “interface pollution” in Go. For instance, unit testing often drives us to rely on interfaces everywhere—especially for passing dependencies. Is that approach itself considered interface pollution? Devs that have C# and Java backgrounds commonly use large, compound interfaces, which you've pointed out is typically an anti-pattern in Go. But at the same time, small, concise interfaces are critical for making Go code testable and mockable. How do we strike a balance between using many small interfaces for testability without polluting the codebase with too many interfaces? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
5-interface-pollution/
None
https://100go.co/5-interface-pollution/
Beta Was this translation helpful? Give feedback.
All reactions