Skip to main content
This guide shows the smallest useful Wyrly setup: a typed port, a concrete implementation, a use case, and a request-like scope.

Create a token

Use tokens to keep interface-based dependencies type-safe at runtime.

Define a use case

@Injectable declares dependencies explicitly. Wyrly does not read constructor parameter types at runtime.

Register providers

Register concrete implementations at the composition root.

Resolve from a scope

Create a scope for request-level work and dispose it when the request finishes.

Validate the graph

Run validation in tests or CI to catch missing providers and lifetime problems early.

Next steps