Darp.Templates
1.12.0
dotnet new install Darp.Templates@1.12.0
Avalonia ExampleProject
This repository contains an example project which can be used to base new projects on.
Features
- Already configured repository
- Platform independent
- Build for any desktop platform
- Easily extensible to mobile platforms
- High performance
PublishAotand trimming is enabled by default- SplashScreen for resource loading on startup
- Personalization by default
- Runtime switching of themes
- Runtime switching of languages (using
.resxand source generation)
- Feature-oriented MVVM structure
- Feature-specific views, view models, and registrations live together
- Route-based shell navigation keeps navigation UI independent from concrete view model types
- WinUI3 styling
- Usage of FluentAvalonia for WinUI3 styles and controls
- Industry tested
- Desktop applications used in the industry were built with the same technologies
- Opinionated toolset
- Microsoft Dependency Injection for DI
- Serilog for Logging
- CommunityToolkit.Mvvm for ObservableProperties and Commands
- Darp.Utils.Dialog for MVVM compatible dialogs
- System.Text.Json with source generation for configuration files
Project structure
The app is organized by feature first, with a small set of app-wide folders:
src/AvaloniaExampleProject/
Assets/ Global assets and localization resources
Features/ User-facing feature slices
Services/ App-wide services and runtime capabilities
Shell/ Main window, app shell, and design-time support
Styling/ Global Avalonia styling resources
Feature-specific UI, view models, and registrations live together under Features/<FeatureName>/. App-wide capabilities such as theming, logging, storage access, and navigation live under Services/.
Preview
How to use this project as a template
Install the Darp.Templates NuGet package:
dotnet new install Darp.Templates
Then create a solution:
dotnet new darp.avalonia.desktop -o MyApp
NuGet packages
- Darp.Templates contains the
darp.avalonia.desktopproject template. - Darp.Avalonia.Camera provides camera capture pipelines and Skia-backed preview controls for Avalonia applications.
Install the camera library separately with:
dotnet add package Darp.Avalonia.Camera
Releasing
The release workflow generates THIRD-PARTY-NOTICES.md from the enriched CycloneDX SBOM
and downloads each referenced SPDX license/exception text once from
spdx/license-list-data/main/text. Desktop packages embed the generated Markdown
before publishing. Settings → About → Open Source libraries displays the package names,
versions, copyright notices, and shared license texts using the same Markdown dialog as
the changelog. Local builds use a placeholder; no generation or downloads run during a local build.
Copyright notices come exclusively from the SBOM. Missing copyright information is reported in the workflow log and displayed explicitly in the dialog. Missing SPDX license identifiers or unavailable license texts fail generation and prevent publishing the release.
Add a versioned section to CHANGELOG.md, then create and push a matching tag:
git tag -a v1.9.0 -m "build: Release v1.9.0"
git push origin v1.9.0
The release workflow validates the tag and changelog, runs formatting and tests, publishes both NuGet packages and desktop packages, and creates the GitHub release from the changelog entry.
Pushes and pull requests to main run validation only. Packaging and publishing run only for release tags.
Parcel builds Windows x64 MSIX, Linux x64 DEB, and macOS Intel/Apple silicon DMG packages.
Set the repository secret AVALONIA_TOOLS_LICENSE_KEY to enable packaging. Windows releases use Azure Trusted Signing; macOS packages use ad-hoc signing and are not notarized.
Further reading
This is an opinionated application template. Additional resources:
About
This is a project by rosslight GmbH
-
net9.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.12.0 | 93 | 11/16/2026 |
| 1.11.1 | 139 | 10/26/2026 |
| 1.11.0 | 131 | 10/25/2026 |
| 1.10.0 | 158 | 10/2/2026 |
| 1.9.0 | 278 | 7/25/2026 |
| 1.8.1 | 252 | 7/24/2026 |
| 1.8.0 | 252 | 7/23/2026 |
| 1.7.0 | 260 | 7/23/2026 |
| 1.6.0 | 300 | 6/27/2026 |
| 1.5.0 | 411 | 3/25/2026 |
| 1.4.0 | 629 | 10/20/2025 |
| 1.3.0 | 726 | 5/26/2025 |
| 1.2.0 | 600 | 5/24/2025 |
| 1.1.3 | 655 | 5/23/2025 |
| 1.1.2 | 658 | 5/23/2025 |