Value Objects
PreviewSource-generated scalar and complex value objects for .NET.
Overview
F#-style single-case types for C#. Mark a partial struct or class with [Scalar] or [ValueObject] and an incremental source generator produces Create/Hydrate factories with normalization and validation, equality, comparison, implicit conversions, JSON converters, and contextual creation. Value objects serialize as their underlying value, map cleanly onto Entity Framework JSON columns, and can be validated with Purview.ZodSharp schemas.
From the repository: Source-generated scalar and complex value objects for .NET - F#-style single-case types with Create/Hydrate factories, normalization, validation, equality, JSON serialization, Entity Framework integration, and ZodSharp validation.
Packages
1 package
| Purview.ValueObjectsInstall ↓ | — | 1.0.0-prerelease.3 | — |
Install
dotnet add package Purview.ValueObjects