I find that when I break up an application into packages by feature, the dependency graph nearly always has this "diamond" shape:
Before I realized this, I struggled a lot. My naive impulse was to have four packages: "Feature 1", "Feature 2", "Feature 3", and a "Common" package for non-feature-specific stuff. This leads to one of three huge mistakes:
Depe…
Keep reading with a 7-day free trial
Subscribe to Type Classes to keep reading this post and get 7 days of free access to the full post archives.