Blazor.WebAssembly.DynamicCulture.Loader 3.2.0

dotnet add package Blazor.WebAssembly.DynamicCulture.Loader --version 3.2.0
                    
NuGet\Install-Package Blazor.WebAssembly.DynamicCulture.Loader -Version 3.2.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="Blazor.WebAssembly.DynamicCulture.Loader" Version="3.2.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Blazor.WebAssembly.DynamicCulture.Loader" Version="3.2.0" />
                    
Directory.Packages.props
<PackageReference Include="Blazor.WebAssembly.DynamicCulture.Loader" />
                    
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 Blazor.WebAssembly.DynamicCulture.Loader --version 3.2.0
                    
#r "nuget: Blazor.WebAssembly.DynamicCulture.Loader, 3.2.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 Blazor.WebAssembly.DynamicCulture.Loader@3.2.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=Blazor.WebAssembly.DynamicCulture.Loader&version=3.2.0
                    
Install as a Cake Addin
#tool nuget:?package=Blazor.WebAssembly.DynamicCulture.Loader&version=3.2.0
                    
Install as a Cake Tool

Blazor.WebAssembly.DynamicCulture.Loader

Nuget Nuget GitHub

A lightweight package for loading satellite culture assemblies at startup in Blazor WebAssembly applications. This package enables dynamic culture switching without requiring page reloads.

📢 Important: Native Blazor Alternative Available

Blazor now provides a native way to load all satellite assemblies in WebAssembly applications. You can configure this in your index.html:

Before:

<script src="_framework/blazor.webassembly.js"></script>

After:

<script src="_framework/blazor.webassembly.js" autostart="false"></script>
<script>
   Blazor.start({ 
       configureRuntime: runtime => runtime.withConfig({ 
           loadAllSatelliteResources: true 
       }) 
   })
</script>

This native approach may eliminate the need for this package as it provides the same core functionality of loading all satellite resource assemblies at startup. However, this package offers:

  • Selective culture loading (load only specific cultures instead of all)
  • Simpler API without manual Blazor startup configuration
  • Compatibility with older Blazor versions that may not support the native feature

Evaluate which solution best fits your project requirements.

📦 Overview

By default, Blazor WebAssembly loads resource assemblies only for the current culture during initial app startup. If you change the culture dynamically later, you must reload the page to load the new resource assemblies.

This package solves that problem by loading all specified localization satellite assemblies simultaneously during startup, eliminating the need for page reloads when switching cultures.

🚀 Getting Started

Installation

Install the package via NuGet:

dotnet add package Blazor.WebAssembly.DynamicCulture.Loader

Usage Examples

Configure culture assembly loading in your Blazor WASM Program.cs:

Option 1: Load and then run

using Blazor.WebAssembly.DynamicCulture.Loader;

var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("#app");

var host = builder.Build();
await host.LoadSatelliteCultureAssembliesCultureAsync(new[] 
{ 
    new CultureInfo("ru"), 
    new CultureInfo("et") 
});
await host.RunAsync();

Option 2: Load and run in one call

using Blazor.WebAssembly.DynamicCulture.Loader;

var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("#app");

await builder.Build().RunWithSatelliteCultureAssembliesAsync(new[] 
{ 
    new CultureInfo("ru"), 
    new CultureInfo("et") 
});

⚠️ Note: Do not use this package for Blazor Server applications. Blazor Server handles resource assemblies differently and does not require this functionality.

🔧 When to Use This Package

Use this package if you:

  • Need to switch cultures dynamically without page reloads
  • Want to load only specific cultures (not all available cultures)
  • Are using an older Blazor version without native loadAllSatelliteResources support
  • Prefer a simpler API over manual Blazor startup configuration

Consider the native Blazor solution if you:

  • Want to load all available satellite resources automatically
  • Are using a recent Blazor version with native support
  • Prefer using built-in Blazor features over third-party packages

📖 Additional Resources

📄 License

This project is licensed under the MIT License. See the LICENSE file for details.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Blazor.WebAssembly.DynamicCulture.Loader:

Package Downloads
Blazor.WebAssembly.DynamicCulture

This package helps to add localization support for your Blazor. This mimics almost the same functionality as `.UseRequestLocalization` for Blazor ServerSide

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
3.2.0 179 1/16/2026
3.2.0-preview1 241 11/26/2025
3.1.0 35,047 7/18/2024
3.0.0 10,020 11/15/2023
3.0.0-preview 279 8/30/2023
2.0.0 1,123 11/21/2022
1.1.0 597 11/15/2022
1.0.0 896 6/17/2022