VijayAnand.MauiBlazor.Markup
2.0.9
Prefix Reserved
See the version list below for details.
dotnet add package VijayAnand.MauiBlazor.Markup --version 2.0.9
NuGet\Install-Package VijayAnand.MauiBlazor.Markup -Version 2.0.9
<PackageReference Include="VijayAnand.MauiBlazor.Markup" Version="2.0.9" />
paket add VijayAnand.MauiBlazor.Markup --version 2.0.9
#r "nuget: VijayAnand.MauiBlazor.Markup, 2.0.9"
// Install VijayAnand.MauiBlazor.Markup as a Cake Addin #addin nuget:?package=VijayAnand.MauiBlazor.Markup&version=2.0.9 // Install VijayAnand.MauiBlazor.Markup as a Cake Tool #tool nuget:?package=VijayAnand.MauiBlazor.Markup&version=2.0.9
.NET MAUI Blazor Toolkit
This toolkit a set of fluent helper methods and classes to simplify working with .NET MAUI Blazor in C#.
This toolkit depends on Microsoft.AspNetCore.Components.WebView.Maui NuGet package.
Most useful method will be Configure
, which can be invoked on an instance of a BlazorWebView and its derivatives, and it simplifies the initialization of BlazorWebView into a single fluent method call as shown in the below sample.
Note: Gateway
is a Razor
component and assumes it can receive a parameter named Foo
as described in the sample underneath.
namespace MyApp;
public class HomePage : ContentPage
{
public HomePage()
{
// A BlazorWebView can manage multiple RootComponents, to achieve this, define another Tuple with values of that component
// The method and Tuple parameter names are shown for clarity and it's optional
// Blazor component can have initialization parameters, which can be supplied thro parameters, a dictionary of keyValues
// where key is of type string and value is of type object
// Without initialization parameters
Content = new BlazorWebView().Configure(hostPage: "wwwroot/index.html", (selector: "#app", componentType: typeof(Gateway), parameters: null));
// With optional initialization parameters
Content = new BlazorWebView().Configure(hostPage: "wwwroot/index.html", (selector: "#app", componentType: typeof(Gateway), parameters: new Dictionary<string, object?> { [nameof(Gateway.Foo)] = "Bar" }));
// In a much simplified form - Real intended usage
// Without initialization parameters
Content = new BlazorWebView().Configure("wwwroot/index.html", ("#app", typeof(Gateway), null));
// With StartPath property introduced in .NET 8 Preview, overloaded Configure method
// Assuming search is the page with which the app is intended to start
Content = new BlazorWebView().Configure("wwwroot/index.html", "/search", ("#app", typeof(Gateway), null));
// With optional initialization parameters
Content = new BlazorWebView().Configure("wwwroot/index.html", ("#app", typeof(Gateway), new Dictionary<string, object?> { [nameof(Gateway.Foo)] = "Bar" }));
}
}
@page "/gateway"
<h2>I'm a razor component named Gateway and I can receive a parameter named Foo.</h2>
@code {
[Parameter]
public string Foo { get; set; }
}
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | 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 was computed. 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. |
-
net7.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on VijayAnand.MauiBlazor.Markup:
Repository | Stars |
---|---|
egvijayanand/dotnet-maui-samples
.NET MAUI Samples
|
Version | Downloads | Last updated |
---|---|---|
4.0.0-rc.2 | 30 | 10/9/2024 |
4.0.0-rc.1 | 36 | 9/11/2024 |
4.0.0-preview.7 | 45 | 8/16/2024 |
4.0.0-preview.6 | 39 | 7/10/2024 |
4.0.0-preview.5 | 39 | 6/12/2024 |
4.0.0-preview.4 | 51 | 5/24/2024 |
4.0.0-preview.3 | 54 | 4/18/2024 |
4.0.0-preview.2 | 60 | 3/17/2024 |
4.0.0-preview.1 | 66 | 2/18/2024 |
3.0.8 | 52 | 7/10/2024 |
3.0.7 | 42 | 6/12/2024 |
3.0.6 | 51 | 5/24/2024 |
3.0.5 | 72 | 4/18/2024 |
3.0.4 | 75 | 4/1/2024 |
3.0.3 | 78 | 3/17/2024 |
3.0.2 | 67 | 2/18/2024 |
3.0.1 | 69 | 1/26/2024 |
3.0.0 | 178 | 11/14/2023 |
3.0.0-rc.2.2 | 59 | 11/7/2023 |
3.0.0-rc.2.1 | 67 | 10/31/2023 |
3.0.0-rc.2 | 61 | 10/13/2023 |
3.0.0-rc.1 | 78 | 9/18/2023 |
3.0.0-preview.7 | 101 | 8/24/2023 |
3.0.0-preview.6 | 84 | 8/8/2023 |
3.0.0-preview.5 | 103 | 4/13/2023 |
3.0.0-preview.4 | 98 | 3/27/2023 |
3.0.0-preview.3 | 94 | 3/21/2023 |
3.0.0-preview.2 | 88 | 3/17/2023 |
3.0.0-preview.1 | 91 | 2/27/2023 |
2.0.10 | 73 | 11/7/2023 |
2.0.9 | 78 | 10/31/2023 |
2.0.8 | 95 | 10/13/2023 |
2.0.7 | 99 | 8/24/2023 |
2.0.6 | 88 | 8/24/2023 |
2.0.5 | 161 | 4/13/2023 |
2.0.4 | 111 | 3/27/2023 |
2.0.3 | 114 | 2/27/2023 |
2.0.1 | 303 | 12/13/2022 |
2.0.0 | 341 | 11/14/2022 |
1.0.12 | 104 | 8/24/2023 |
1.0.11 | 96 | 3/27/2023 |
1.0.10 | 107 | 2/27/2023 |
1.0.8 | 292 | 12/13/2022 |
1.0.7 | 325 | 11/14/2022 |
1.0.1 | 443 | 6/15/2022 |
1.0.0 | 635 | 5/23/2022 |
1.0.0-pre7 | 141 | 5/11/2022 |
1.0.0-pre6 | 153 | 4/28/2022 |
1.0.0-pre5 | 144 | 4/12/2022 |
1.0.0-pre4 | 139 | 3/18/2022 |
1.0.0-pre3 | 155 | 2/25/2022 |
1.0.0-pre2 | 171 | 1/31/2022 |
1.0.0-pre1 | 126 | 1/31/2022 |
Join me on Developer Thoughts, https://egvijayanand.in/, an exclusive blog for .NET MAUI and Blazor.
What's new in ver. 2.0.9:
-------------------------
This version of package is released on top of .NET MAUI SR9 (ver. 7.0.100) on .NET 7.
v2.0.8:
This version of package is released on top of .NET MAUI SR8 (ver. 7.0.96) on .NET 7.
v2.0.7:
This version of package is released on top of .NET MAUI SR7 (ver. 7.0.92) on .NET 7.
v2.0.6:
This version of package is released on top of .NET MAUI SR6 (ver. 7.0.86) on .NET 7.
v2.0.5:
This version of package is released on top of .NET MAUI SR4 (ver. 7.0.81) on .NET 7.
v2.0.4:
Added a generic version of Add extension method for the RootComponents collection, inspired from WindowsForms package.
v2.0.3:
This version of package is released on top of .NET MAUI on .NET 7 SR3 (7.0.59) version.
v2.0.1:
This version of package is released on top of .NET MAUI on .NET 7 SR1.1 (7.0.52) version.
v2.0.0:
This version of package is released on top of .NET MAUI on .NET 7 GA (7.0.49) version.