Skip to content

Installation

This guide will walk you through the process of installing MudBlazor.Extensions in your Blazor project.

Prerequisites

Before installing MudBlazor.Extensions, ensure you have:

  • A Blazor project (WebAssembly, Server, or Hybrid)
  • MudBlazor installed and configured
  • .NET 6.0 or later

MudBlazor Required

MudBlazor.Extensions requires MudBlazor to be installed. If you haven't installed MudBlazor yet, visit the official MudBlazor documentation for installation instructions.

Installation Methods

Using .NET CLI

The easiest way to install MudBlazor.Extensions is via the .NET CLI:

dotnet add package MudBlazor.Extensions

Using Package Manager Console

In Visual Studio, you can use the Package Manager Console:

Install-Package MudBlazor.Extensions

Using Visual Studio NuGet Manager

  1. Right-click on your project in Solution Explorer
  2. Select "Manage NuGet Packages"
  3. Search for "MudBlazor.Extensions"
  4. Click "Install"

Manual Package Reference

Add the package reference directly to your .csproj file:

<ItemGroup>
  <PackageReference Include="MudBlazor.Extensions" Version="*" />
</ItemGroup>

Version Selection

Using Version="*" will always get the latest version. For production, it's recommended to specify a specific version number.

Verify Installation

After installation, verify that the package is correctly installed:

  1. Build your project to ensure there are no errors
  2. Check your project file to confirm the package reference exists
  3. Restore packages if needed:
dotnet restore

Platform-Specific Considerations

Blazor WebAssembly

No additional steps required. The package works out of the box.

Blazor Server

For Blazor Server applications, you may need to add middleware (see Setup page).

MAUI Blazor Hybrid

The package is compatible with MAUI Blazor Hybrid applications. Follow the standard installation steps.

Troubleshooting

Package Not Found

If you encounter issues finding the package:

  1. Ensure your NuGet sources include nuget.org
  2. Clear your NuGet cache:
dotnet nuget locals all --clear
  1. Try restoring packages again:
dotnet restore

Version Conflicts

If you encounter version conflicts with MudBlazor:

  1. Ensure you're using compatible versions
  2. Check the changelog for compatibility information
  3. Update MudBlazor to the latest version if needed

Build Errors After Installation

If you experience build errors:

  1. Clean your solution:
dotnet clean
  1. Rebuild:
dotnet build
  1. If issues persist, try deleting the bin and obj folders and rebuilding

Next Steps

Now that you have MudBlazor.Extensions installed, proceed to the Setup guide to configure it in your application.

Getting Help

If you encounter issues during installation: