Understanding the Law of Demeter ↦
I almost brought up the Law of Demeter on Go Time a couple weeks back:
That being said, sometimes you just have to follow the other person’s path until you realize when it doesn’t actually work for you. I’m totally fine with cargo-culting some sort of rule… I was gonna say the Law of Demeter, but that one’s too hard to explain. What’s a very simple – DRY, right?
See how quickly I abandoned ship there? Ok, it’s not that hard to explain. I just didn’t feel like taking the time to explain it when it wasn’t even my point. Good thing Double Agent Caleb Hearth did a nice write-up on Test Double’s blog about it!
Discussion
Sign in or Join to comment or subscribe