Where code livesintermediate
A vertical slice keeps one feature — its endpoint, its validation, its data access — in one folder, so changing checkout means opening one place instead of four layers.
A 90-line God Method doing validation, data access and payment in one controller. Make it a slice.
One self-contained slice, one round trip per update, and machine-readable failures.
Published in full, before you start — every point is one of these and there is nothing else.
A vertical slice keeps one feature — its endpoint, its validation, its data access — in one folder, so changing checkout means opening one place instead of four layers.
Primary constructors put dependencies in the class declaration and delete the field-plus-assignment ceremony that used to take six lines to say one thing.
IQueryable lets you build a query in pieces and send one efficient SQL statement — the classic mistake is fetching every row into memory and filtering there.
A raw exception string tells the caller nothing they can act on; RFC 7807 ProblemDetails gives every failure the same machine-readable shape.