Joinery.Dovetail
0.7.0
dotnet add package Joinery.Dovetail --version 0.7.0
NuGet\Install-Package Joinery.Dovetail -Version 0.7.0
<PackageReference Include="Joinery.Dovetail" Version="0.7.0" />
<PackageVersion Include="Joinery.Dovetail" Version="0.7.0" />
<PackageReference Include="Joinery.Dovetail" />
paket add Joinery.Dovetail --version 0.7.0
#r "nuget: Joinery.Dovetail, 0.7.0"
#:package Joinery.Dovetail@0.7.0
#addin nuget:?package=Joinery.Dovetail&version=0.7.0
#tool nuget:?package=Joinery.Dovetail&version=0.7.0
Dovetail
Joint-driven application wiring for .NET. A library declares the configuration, services, logging and hosting it needs as joints, and a Roslyn source generator finds them at build time. Referencing a package is enough to wire it up: there is no extension method to remember, no assembly scanning and no runtime reflection, so Dovetail apps work with Native AOT and trimming.
Documentation: https://rocketsurgeonsguild.github.io/Dovetail/
Getting started
The shortest path is to swap your project's Microsoft SDK for its Dovetail counterpart. The SDK detects the kind of host, adds the Dovetail packages it needs and writes the bootstrapping code:
<Project Sdk="Microsoft.NET.Sdk.Web">
<Project Sdk="Joinery.Dovetail.Sdk.Web">
Pin the version in global.json under msbuild-sdks. See Dovetail SDKs for each Microsoft SDK.
A joint is a class that implements one of the joint interfaces. Mark it with [DovetailExport] and any application that
references your library picks it up:
[DovetailExport]
public class TimeJoint : IServiceJoint
{
public void Register(IDovetailContext context, IServiceCollection services)
{
services.AddSingleton(TimeProvider.System);
}
}
See Defining joints for the full set of joint types, host types and categories.
Packages
| Package | NuGet | What it does |
|---|---|---|
| Joinery.Dovetail | The joint interfaces, DovetailContextBuilder and the source generator |
|
| Joinery.Dovetail.Hosting | Bootstraps the generic host, ASP.NET Core, .NET MAUI, Uno Platform and Blazor WebAssembly from your joints | |
| Joinery.Dovetail.Configuration.Json | Loads JSON configuration files, such as appsettings.json |
|
| Joinery.Dovetail.Configuration.Yaml | Loads YAML configuration files, such as appsettings.yaml |
|
| Joinery.Dovetail.Configuration.Toml | Loads TOML configuration files, such as appsettings.toml |
|
| Joinery.Dovetail.Serilog | Serilog joint for LoggerConfiguration |
|
| Joinery.Dovetail.OpenTelemetry | OpenTelemetry joint for IOpenTelemetryBuilder |
|
| Joinery.Dovetail.Autofac | Autofac joint for ContainerBuilder |
|
| Joinery.Dovetail.DryIoc | DryIoc joint for IContainer |
|
| Joinery.Dovetail.Stashbox | Stashbox joint for IStashboxContainer |
|
| Joinery.Dovetail.Aspire | Applies joints to an Aspire IDistributedApplicationBuilder |
|
| Joinery.Dovetail.Aspire.Testing | Applies joints to an Aspire IDistributedApplicationTestingBuilder |
|
| Joinery.Dovetail.Testing | Runs shared test setup joints when the host is a unit test host | |
| Joinery.Dovetail.ModularPipelines | Applies joints to a ModularPipelines PipelineBuilder |
|
| Joinery.Dovetail.Mermaid | Renders a context's resolved joints as a Mermaid diagram |
MSBuild SDKs
Each SDK is a drop-in replacement for the Microsoft SDK it names.
| Package | NuGet | Replaces |
|---|---|---|
| Joinery.Dovetail.Sdk | Microsoft.NET.Sdk: console apps, libraries, test projects and file-based apps |
|
| Joinery.Dovetail.Sdk.Web | Microsoft.NET.Sdk.Web: ASP.NET Core applications |
|
| Joinery.Dovetail.Sdk.Worker | Microsoft.NET.Sdk.Worker: worker services |
|
| Joinery.Dovetail.Sdk.Razor | Microsoft.NET.Sdk.Razor: Razor class libraries |
|
| Joinery.Dovetail.Sdk.BlazorWebAssembly | Microsoft.NET.Sdk.BlazorWebAssembly: Blazor WebAssembly applications |
|
| Joinery.Dovetail.Sdk.WebAssembly | Microsoft.NET.Sdk.WebAssembly: WebAssembly applications |
|
| Joinery.Dovetail.Sdk.WindowsDesktop | Microsoft.NET.Sdk.WindowsDesktop: Windows Forms and WPF |
|
| Joinery.Dovetail.Sdk.Aspire.AppHost | Aspire.AppHost.Sdk: Aspire AppHost projects |
|
| Joinery.Dovetail.Sdk.Console | Joinery.Dovetail.Sdk plus a generated Program.cs for ConsoleAppFramework apps |
Joinery.Dovetail.Analyzers holds the source generator. Joinery.Dovetail brings it in, so you don't reference it
yourself.
Configuration
Options binding and configuration schemas come from Optionary, which
Dovetail doesn't depend on. Add the Optionary package and put [Optionary] on an options class: Optionary generates a
reflection-free binder for IOptions<T> and a JSON Schema, and Dovetail exports a joint that registers the options in every host
that references the library. A library's appsettings files in JSON, YAML or TOML are still shipped by the Dovetail SDK. See
Configuration with Optionary and
Configuration Files.
Contributing
Run mise install before building: it installs the .NET SDK and the extra .NET 10 runtime that the net10.0 tests run on (.config/mise.toml). global.json pins the same SDK, so a dotnet outside mise fails fast unless that SDK is installed.
On macOS, the first mise install of a new .NET SDK can overwrite the shared ~/.local/share/mise/dotnet-root/dotnet host in place, and macOS then kills every dotnet command (SIGKILL). Replace the host with a fresh copy to fix it:
cd ~/.local/share/mise/dotnet-root && cp -p dotnet dotnet.fresh && mv -f dotnet.fresh dotnet
| Product | Versions 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. net11.0 is compatible. |
-
net10.0
- Joinery.Dovetail.Analyzers (>= 0.7.0)
- Microsoft.Extensions.Configuration (>= 10.0.15)
- Microsoft.Extensions.DependencyInjection (>= 10.0.15)
- Microsoft.Extensions.Logging (>= 10.0.15)
- Microsoft.Extensions.Logging.Configuration (>= 10.0.15)
- Microsoft.Extensions.Options (>= 10.0.15)
- Microsoft.Extensions.Options.ConfigurationExtensions (>= 10.0.15)
-
net11.0
- Joinery.Dovetail.Analyzers (>= 0.7.0)
- Microsoft.Extensions.Configuration (>= 11.0.0)
- Microsoft.Extensions.DependencyInjection (>= 11.0.0)
- Microsoft.Extensions.Logging (>= 11.0.0)
- Microsoft.Extensions.Logging.Configuration (>= 11.0.0)
- Microsoft.Extensions.Options.ConfigurationExtensions (>= 11.0.0)
NuGet packages (18)
Showing the top 5 NuGet packages that depend on Joinery.Dovetail:
| Package | Downloads |
|---|---|
|
Joinery.Dovetail.Serilog
Adds a Serilog joint, so libraries can configure the application's Serilog LoggerConfiguration, and reads Serilog minimum levels from configuration. |
|
|
Joinery.Dovetail.Hosting
Builds and configures a host from an application's joints. Covers the generic host, ASP.NET Core, .NET MAUI, Uno Platform and Blazor WebAssembly; the helpers for a host are emitted when the application references its framework. |
|
|
Joinery.Dovetail.OpenTelemetry
Adds an OpenTelemetry joint, so libraries can add their tracing, metrics and logging setup to the application's IOpenTelemetryBuilder. |
|
|
Joinery.Dovetail.DryIoc
Uses DryIoc as the application's container and adds a DryIoc joint, so libraries can register services on its IContainer. |
|
|
Joinery.Dovetail.Configuration.Yaml
Configuration joint that adds appsettings.yaml (or .yml) and its environment-specific files through a YamlDotNet configuration provider, including embedded and Blazor WebAssembly wwwroot files. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.7.0 | 0 | 11/16/2026 |
| 0.6.0 | 0 | 11/16/2026 |
| 0.5.3 | 778 | 11/13/2026 |
| 0.5.2 | 90 | 11/13/2026 |
| 0.5.1 | 100 | 11/13/2026 |
| 0.5.0 | 127 | 11/12/2026 |
| 0.4.5 | 141 | 11/11/2026 |
| 0.4.4 | 317 | 11/8/2026 |
| 0.4.3 | 964 | 11/8/2026 |
| 0.4.2 | 472 | 11/2/2026 |
| 0.4.1 | 201 | 11/1/2026 |
| 0.4.0 | 310 | 10/31/2026 |
| 0.3.1 | 214 | 10/31/2026 |
| 0.3.0 | 207 | 10/29/2026 |
| 0.2.3 | 209 | 10/28/2026 |