🚀 Start Here

# Cohesion

📅 Sun, September 24th 2023

I used to keep tech together, clothes together, smaller accessories together. That makes logical sense. Keep like things together, and you know where to find the thing you need.

This is horizontal organisation.

Looking at it through the lense of utility though, it makes less sense. To prepare for karting, I’d need to go in the tech box for the GoPro, the accessories box for a balaclava, clothing for karting gear, etc.

Also, as I’m grabbing things from different boxes at different rates, those boxes get disorganised. It’s harder & harder to find things used slightly less often.

This is bad cohesion. Logical, but not practical.

Like things together

Instead, I now try to put things that are used together, together. I can go to one place to get my running kit, tech such as my garmin, and accessories like the flip-belt I use to carry gels. By organising things based on the way they are used, life becomes easier.

Things stay tidier too, because things kept together are moving and changing at the same rate.

Used together, kept together

Trigger a code segue: modular code usually means horizontal layers based on similar things, e.g. modules dealing with validations, hydration, pricing, etc. When these modules are shared between use cases, this might mean changing multiple modules to implement changes and features.

This can get messy. Module methods that change less often fall behind, diverge from other things in the module, as style & approaches change.

Changes in multiple places also runs the risk of bugs across multiple use cases, meaning more risk & more testing.

Consider putting things that are used together, together.