Comment

Comment by euroderf

> In my opinion, not allowing circular dependencies is a great design choice for building large programs.

I have a hobby project with maybe 20 packages involved. Circular dependencies were getting harder and harder to solve.

What worked in this situation was to separate the whole hairball into two layers. The packages in the app layer could import packages from the utilities layer, but not vice-versa.

This introduced enough structure to simplify the removal of circularities and prevent new outbreaks.

parent euroderf 1 year ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton