fn(args, deps) and Hexagonal Architecture
17 Mar 2026Hexagonal architecture often gets introduced with a lot of diagrams, vocabulary, and ceremony.
Ports. Adapters. Application core. Inbound and outbound boundaries.
That framing is useful, but it can also make the idea feel more abstract than it really is.
A simpler way to understand it is this:
Hexagonal architecture is mostly about keeping business logic independent from delivery and infrastructure details.
One practical way to do that in plain TypeScript is this shape:
fn(args, deps);
Where args is the input for this use case, and deps is the set of external capabilities it needs.
You can read that as: data in, capabilities in.
Read More →In plain TypeScript,
fn(args, deps)is a simple way to implement the core idea of hexagonal architecture without turning the pattern into ceremony.