Skip to content

Commit

Permalink
Blazor sample
Browse files Browse the repository at this point in the history
  • Loading branch information
aritchie committed Jun 4, 2024
1 parent 1acad20 commit e587908
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
5 changes: 4 additions & 1 deletion Sample/MauiProgram.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,10 @@ public static MauiApp CreateMauiApp()
builder.Logging.AddDebug();
builder.Services.AddBlazorWebViewDeveloperTools();
#endif
builder.Services.AddShinyMediator(x => x.UseMaui());
builder.Services.AddShinyMediator(x => x
.UseMaui()
.UseBlazor()
);
builder.Services.AddSingletonAsImplementedInterfaces<SingletonEventHandler>();
builder.Services.AddSingletonAsImplementedInterfaces<SingletonRequestHandler>();
builder.Services.AddSingletonAsImplementedInterfaces<MyRequestMiddleware>();
Expand Down
1 change: 1 addition & 0 deletions Sample/Sample.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\src\Shiny.Mediator.Blazor\Shiny.Mediator.Blazor.csproj" />
<ProjectReference Include="..\src\Shiny.Mediator.Contracts\Shiny.Mediator.Contracts.csproj"/>
<ProjectReference Include="..\src\Shiny.Mediator.Maui\Shiny.Mediator.Maui.csproj"/>
<ProjectReference Include="..\src\Shiny.Mediator.SourceGenerators\Shiny.Mediator.SourceGenerators.csproj"/>
Expand Down
5 changes: 4 additions & 1 deletion src/Shiny.Mediator.Blazor/BlazorExtensions.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
namespace Shiny.Mediator.Blazor;
using Shiny.Mediator.Blazor;

namespace Shiny.Mediator;


public static class BlazorExtensions
{
Expand Down

0 comments on commit e587908

Please sign in to comment.