Fundamentals
Fundamentals
The building blocks beneath the stack
Shared primitives for domain values and infrastructure, with implementations for C#, TypeScript, Kotlin and Java, and Go. APIs and package coverage differ: choose the building blocks your language provides, without adopting the rest of Cratis.
Choose your platform
Section titled “Choose your platform”Concepts, serialization, DI, type discovery, metrics, monads, and reactive helpers for .NET.
TypeScriptGUIDs, derived-type serialization, property-path proxies, and decorators for the browser.
GoTyped concepts and scalar codecs, correlation, naming, and optional dependency injection for Go programs.
For Kotlin and Java, start with the JVM repository’s README for language-specific concept and Jackson examples. Its compatibility reference records supported contracts and wire differences. These pages are not mounted in this documentation site; do not infer C# API equivalents.
Use a building block on its own
Section titled “Use a building block on its own”You do not need to adopt the rest of Cratis to use Fundamentals. Start with TypeScript concepts, the Go domain-value guide, or the standalone C# concept example.
The platforms offer different building blocks. For example, the C# Option, Result, and Catch chapter needs only a console app and the core NuGet package, not a database or host. It does not imply equivalent monad APIs in TypeScript, JVM, or Go.
What it gives you
Section titled “What it gives you”The cards below lead to C# APIs and the C#/TypeScript derived-type integration. For other implementations, use the platform guides above. In particular, check Go’s parity map before carrying a serialization or container contract across.
The ConceptAs<T> pattern that wraps an AuthorId so the compiler stops you mixing ids up.
Robust JSON with custom and derived-type handling — what carries events across the wire.
Dependency injectionConvention-based registration so artifacts are discovered, not hand-wired.
Derived typesHow polymorphic types travel between .NET and TypeScript without losing their identity.
On .NET, Fundamentals supports convention-based artifact discovery for Chronicle and Arc. Other implementations have their own registration and discovery mechanisms; shared names do not establish runtime parity. See Why developers choose Cratis.