Forge.Delta 1.20.0

dotnet add package Forge.Delta --version 1.20.0
                    
NuGet\Install-Package Forge.Delta -Version 1.20.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Forge.Delta" Version="1.20.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Forge.Delta" Version="1.20.0" />
                    
Directory.Packages.props
<PackageReference Include="Forge.Delta" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Forge.Delta --version 1.20.0
                    
#r "nuget: Forge.Delta, 1.20.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Forge.Delta@1.20.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Forge.Delta&version=1.20.0
                    
Install as a Cake Addin
#tool nuget:?package=Forge.Delta&version=1.20.0
                    
Install as a Cake Tool

Forge.Delta

Compile-time, strongly typed state differences for .NET 10.

Forge.Delta generates comparison code for your models at build time. Runtime comparison uses direct property access: no reflection, dynamic proxies, hidden I/O, or DI requirement.

Install

dotnet add package Forge.Delta

Quick start

using Forge.Delta;

[GenerateDelta]
public sealed record Customer(
    Guid Id,
    string Name,
    string? Email);

var delta = CustomerDelta.Between(before, after);

if (delta.EmailChange.HasChanged)
{
    Console.WriteLine($"{delta.EmailChange.Before} -> {delta.EmailChange.After}");
}

The generated API also provides:

CustomerDelta.AreEquivalent(before, after);
CustomerDelta.GetSemanticHashCode(after);
CustomerDelta.AnalyzeMerge(baseline, current, desired);
delta.Invert();

Explicit semantics

Use [DeltaIgnore] for state that does not participate in comparison and [DeltaComparer] when domain equality differs from default equality.

Forge.Delta also supports nested generated deltas, external/unannotated models through [GenerateDeltaProfile], and explicit collection comparers for sequence, unordered, set, dictionary, and keyed-list semantics.

Forge does not recursively guess arbitrary object-graph or collection semantics.

When to use Forge.Sync

Delta answers:

What changed inside this object?

If you instead need to reconcile complete or partial keyed collections into Added / Updated / Removed / Unchanged, use Forge.Sync. Every generated Sync update carries its generated Delta.

Runtime characteristics

  • .NET 10
  • source-generated
  • Native AOT and trimming friendly
  • no runtime reflection in generated comparison paths
  • no mandatory DI
  • no infrastructure dependency

Three-way resolution

AnalyzeMerge can be followed by explicit conflict resolution without mutating your domain object:

var analysis = CustomerDelta.AnalyzeMerge(baseline, current, desired);
var resolved = MergeResolver.Resolve(
    analysis,
    new MergeResolutionPolicy()
        .PreferDesired("Email")
        .PreferCurrent("LastObservedAt"));

Non-conflicting branch changes are combined automatically. Conflicts without a configured policy remain explicit in UnresolvedConflicts.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Forge.Delta:

Package Downloads
Forge.Sync

Compile-time desired-state reconciliation and transition planning for .NET.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.20.0 132 9/27/2026

Forge.Delta 1.20.0: Delta API remains compatible; family version aligned with the Forge 1.20 planning release.