Installation Guide
Prerequisites
- .NET SDK 8.0 or later (9.0 recommended)
- A compatible IDE (Visual Studio 2022, VS Code, Rider)
Installing via NuGet
Core Package
The core package is the foundation for all other packages:
bash
dotnet add package Nextended.CoreOr via Package Manager Console in Visual Studio:
powershell
Install-Package Nextended.CoreInstalling Additional Packages
Install only the packages you need for your project:
For Blazor applications:
bash
dotnet add package Nextended.BlazorFor Entity Framework projects:
bash
dotnet add package Nextended.EFFor ASP.NET Core applications:
bash
dotnet add package Nextended.WebFor caching functionality:
bash
dotnet add package Nextended.CacheFor image processing:
bash
dotnet add package Nextended.ImagingFor WPF/Windows applications:
bash
dotnet add package Nextended.UIFor code generation:
bash
dotnet add package Nextended.CodeGen
dotnet add package Nextended.Core --version [version]For .NET Aspire applications:
bash
dotnet add package Nextended.AspireVersion Compatibility
All Nextended packages share the same version number. Current version: 9.0.x
.NET Version Support
| Nextended Version | .NET Standard 2.0 | .NET Standard 2.1 | .NET 8.0 | .NET 9.0 |
|---|---|---|---|---|
| 9.0.x | ✅ | ✅ | ✅ | ✅ |
| 8.0.x | ✅ | ✅ | ✅ | ❌ |
| 7.0.x | ✅ | ✅ | ❌ | ❌ |
Framework Compatibility
- .NET Framework: 4.6.1+ (via .NET Standard 2.0)
- .NET Core: 2.0+ (via .NET Standard 2.0)
- .NET: 5.0, 6.0, 7.0, 8.0, 9.0
Project Setup
Basic Console Application
- Create a new console application:
bash
dotnet new console -n MyApp
cd MyApp- Add Nextended.Core:
bash
dotnet add package Nextended.Core- Use Nextended in your code:
csharp
using Nextended.Core.Extensions;
using Nextended.Core.Types;
var today = Date.Today;
Console.WriteLine($"Today is: {today}");
var text = "hello world";
Console.WriteLine(text.ToPascalCase()); // Output: HelloWorldASP.NET Core Web Application
- Create a new web application:
bash
dotnet new web -n MyWebApp
cd MyWebApp- Add required packages:
bash
dotnet add package Nextended.Core
dotnet add package Nextended.Web- Use in your application:
csharp
using Nextended.Core.Extensions;
using Nextended.Web.Extensions;
var builder = WebApplication.CreateBuilder(args);
var app = builder.Build();
app.MapGet("/", (HttpContext context) =>
{
var userAgent = context.Request.Headers["User-Agent"].ToString();
return $"Hello! You are using: {userAgent}";
});
app.Run();Blazor Application
- Create a new Blazor application:
bash
dotnet new blazor -n MyBlazorApp
cd MyBlazorApp- Add Blazor package:
bash
dotnet add package Nextended.Blazor- Use Blazor extensions in your components:
razor
@using Nextended.Blazor.Extensions
@using Nextended.Core.Extensions
<h3>Welcome</h3>
<p>@userName.ToPascalCase()</p>
@code {
private string userName = "john doe";
}Entity Framework Project
- Add EF package:
bash
dotnet add package Nextended.EF
dotnet add package Microsoft.EntityFrameworkCore
dotnet add package Microsoft.EntityFrameworkCore.SqlServer- Use EF extensions:
csharp
using Nextended.EF;
using Microsoft.EntityFrameworkCore;
public class ApplicationDbContext : DbContext
{
public DbSet<User> Users { get; set; }
}
// Multi-property substring search
var users = await dbContext.Users
.WhereContains(searchTerm, u => u.Name, u => u.Email)
.ToListAsync();
// Paged + dynamically sorted result with metadata
var page = await dbContext.Users
.OrderByMember("name")
.ToPagedResultAsync(pageIndex: 0, pageSize: 25);Code Generation Setup
Setting up Nextended.CodeGen
- Add packages to your project:
bash
dotnet add package Nextended.CodeGen
dotnet add package Nextended.Core- Create a configuration file
CodeGen.config.json:
json
{
"DtoGeneration": {
"Namespace": "MyApp.Generated",
"Suffix": "Dto"
}
}- Add the config file to your
.csproj:
xml
<ItemGroup>
<AdditionalFiles Include="CodeGen.config.json" />
</ItemGroup>- Mark classes for generation:
csharp
using Nextended.Core.Attributes;
[AutoGenerateDto]
public class User
{
public int Id { get; set; }
public string Name { get; set; }
}- Build your project - the DTO will be generated automatically!
Verifying Installation
After installation, verify everything works:
bash
dotnet buildYou should see no errors. To verify the packages are installed:
bash
dotnet list packageTroubleshooting
Package Not Found
If you get a "Package not found" error:
- Ensure you have the latest NuGet sources:
dotnet nuget list source - Clear NuGet cache:
dotnet nuget locals all --clear - Restore packages:
dotnet restore
Version Conflicts
If you experience version conflicts:
- Ensure all Nextended packages use the same version
- Check for transitive dependency conflicts
- Use
dotnet list package --include-transitiveto diagnose
Windows-Only Package Issues
If building Nextended.UI on non-Windows platforms:
- This package requires Windows and will not build on Linux/macOS
- Exclude it from cross-platform builds or use conditional compilation
Code Generation Issues
If generated code is not appearing:
- Ensure
CodeGen.config.jsonis marked asAdditionalFiles - Clean and rebuild the project:
dotnet clean && dotnet build - Check the build output for code generation messages
- Verify source generators are enabled in your IDE
Next Steps
- Review the Architecture Overview
- Explore Common Use Cases
- Check out the API Reference
- Read individual Project Documentation