30 Write Cohesive Code
“You are about to write some new code, and the first decision you need to make is where to put it. It doesn’t really matter where it goes, so just go ahead and add it to the class that happens to be open in your IDE now. It’s easier to keep track of code when it’s all in one big class or component anyway.” |
Cohesion is a measure of how functionally related the members of a component (package, module, or assembly) are. A higher value of cohesion indicates that the members work toward one feature or set of features. ...
Get Practices of an Agile Developer now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.