VijayAnand.MauiTemplates
1.6.0
Prefix Reserved
See the version list below for details.
dotnet new install VijayAnand.MauiTemplates::1.6.0
Project and Item Templates for developing .NET MAUI App that runs on iOS, Android, macOS, and Windows
All-in-One project template for .NET MAUI App and is named as mauiapp
.NET MAUI Class Library project template and is named as mauiclasslib
Item templates for the following:
Item | Template Name |
---|---|
ContentPage (XAML) | maui-page |
ContentPage (C#) | maui-page-cs |
ContentView (XAML) | maui-view |
ContentView (C#) | maui-view-cs |
Shell (XAML) | maui-shell |
ResourceDictionary (XAML) | maui-resdict |
All of these templates currently target .NET MAUI RC3
, latest release as of May 2022.
To install the template NuGet package, use the below .NET CLI command:
dotnet new --install VijayAnand.MauiTemplates
If you've already installed this package, then it can be updated to the latest version with the below command:
dotnet new --update-check
dotnet new --update-apply
Use the below .NET CLI command to create the all-in-one .NET MAUI App, library project, pages, and views out these templates:
Note: Parameter values are case-insensitive.
Both project templates take the below optional parameters to include the official CommunityToolkit NuGet packages:
-it
|--include-toolkit
- Accepted Values areYes
orNo
(default isNo
)-im
|--include-markup
- Accepted Values areYes
orNo
(default isNo
)-imt
|--include-mvvm-toolkit
- Accepted Values areYes
orNo
(default isNo
)
All-in-One .NET MAUI App project takes one additional parameter to define the application design pattern:
-dp
|--design-pattern
Can take any one of the following values, with default value set to Plain
:
Parameter Value | Description |
---|---|
Plain | App configured to work with a single, initial screen. |
Hierarchical | App configured to work in a hierarchical pattern using NavigationPage. |
Tab | App configured to work in a Tabbed fashion using TabbedPage. |
Shell | App configured to work with Routes using Shell page. |
Hybrid | App configured to work in a Hybrid fashion using BlazorWebView. |
For more details: run this command in the terminal (use -h
to save some keystrokes):
dotnet new mauiapp --help
dotnet new mauiclasslib --help
.NET MAUI App:
dotnet new mauiapp -n MyApp -dp Hybrid
Option to include NuGet packages:
dotnet new mauiapp -n MyApp -dp Shell -it yes -im yes -imt yes
.NET MAUI Class Library:
dotnet new mauiclasslib -n MyApp.Core
Option to include NuGet packages:
dotnet new mauiclasslib -n MyApp.Core -it yes -im yes -imt yes
Pages:
dotnet new maui-page -n LoginPage -na MyApp.Views
dotnet new maui-page-cs -n HomePage -na MyApp.Views
Views:
dotnet new maui-view -n CardView -na MyApp.Views
dotnet new maui-view-cs -n OrderView -na MyApp.Views
Shell:
dotnet new maui-shell -n AppShell -na MyApp
Resource Dictionary:
With code-behind C# file:
dotnet new maui-resdict -n DarkTheme -na MyApp
Without code-behind C# file (Here -ncb
| --no-code-behind
denotes the option to exclude the C# file):
dotnet new maui-resdict -n DarkTheme -na MyApp -ncb
In all the examples, -n
denotes the name of the project/page/view that is to be created (for pages/views, don't need to suffix it with .xaml, it will be added automatically) (Can also be specified as --name
).
Note: If name
parameter input is not provided, the .NET CLI template engine will take the current folder name in the context as its name (default behavior).
And -na
denotes the namespace under which the file is to be created (Can also be specified as --namespace
).
-
.NETStandard 2.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
7.3.1 | 49 | 4/11/2025 |
7.2.0 | 89 | 3/20/2025 |
7.1.0 | 57 | 3/14/2025 |
7.0.1 | 119 | 3/8/2025 |
7.0.0 | 89 | 3/8/2025 |
6.2.0 | 144 | 1/20/2025 |
6.1.0 | 178 | 11/29/2024 |
6.0.0 | 80 | 11/19/2024 |
5.15.0 | 121 | 10/23/2024 |
5.14.0 | 86 | 10/10/2024 |
5.13.0 | 132 | 9/13/2024 |
5.12.1 | 121 | 8/15/2024 |
5.12.0 | 81 | 8/14/2024 |
5.11.0 | 74 | 8/5/2024 |
5.10.1 | 61 | 8/1/2024 |
5.10.0 | 79 | 7/26/2024 |
5.9.0 | 103 | 7/9/2024 |
5.8.0 | 79 | 7/5/2024 |
5.7.0 | 82 | 6/28/2024 |
5.6.2 | 94 | 6/13/2024 |
5.6.1 | 67 | 6/12/2024 |
5.6.0 | 68 | 6/11/2024 |
5.5.0 | 80 | 6/6/2024 |
5.4.0 | 247 | 5/22/2024 |
5.3.0 | 267 | 5/14/2024 |
5.2.1 | 146 | 4/17/2024 |
5.2.0 | 99 | 4/10/2024 |
5.1.0 | 413 | 3/12/2024 |
5.0.1 | 748 | 2/18/2024 |
5.0.0 | 204 | 2/14/2024 |
4.9.0 | 236 | 2/8/2024 |
4.8.1 | 620 | 1/18/2024 |
4.8.0 | 164 | 1/15/2024 |
4.7.0 | 385 | 1/4/2024 |
4.6.0 | 1,074 | 11/30/2023 |
4.5.0 | 248 | 11/24/2023 |
4.4.0 | 381 | 11/14/2023 |
4.4.0-preview.5 | 192 | 11/10/2023 |
4.4.0-preview.4 | 111 | 11/9/2023 |
4.4.0-preview.3 | 319 | 10/30/2023 |
4.4.0-preview.2 | 386 | 10/18/2023 |
4.4.0-preview.1 | 116 | 10/18/2023 |
4.3.0 | 300 | 10/13/2023 |
4.2.2 | 263 | 10/7/2023 |
4.2.1 | 195 | 10/4/2023 |
4.2.0 | 131 | 10/4/2023 |
4.1.1 | 159 | 9/26/2023 |
4.1.0 | 183 | 9/13/2023 |
4.0.1 | 184 | 8/27/2023 |
4.0.0 | 152 | 8/17/2023 |
3.6.0 | 159 | 8/10/2023 |
3.5.0 | 191 | 7/14/2023 |
3.4.1 | 206 | 6/14/2023 |
3.4.0 | 134 | 6/13/2023 |
3.3.2 | 183 | 5/18/2023 |
3.3.1 | 133 | 5/17/2023 |
3.3.0 | 138 | 5/16/2023 |
3.2.4 | 207 | 4/20/2023 |
3.2.3 | 155 | 4/17/2023 |
3.2.2 | 146 | 4/14/2023 |
3.2.1 | 146 | 4/11/2023 |
3.2.0 | 148 | 4/5/2023 |
3.2.0-preview.6 | 129 | 4/3/2023 |
3.2.0-preview.5 | 128 | 4/2/2023 |
3.2.0-preview.4 | 125 | 3/30/2023 |
3.2.0-preview.3 | 132 | 3/27/2023 |
3.2.0-preview.2 | 132 | 3/25/2023 |
3.2.0-preview.1 | 126 | 3/24/2023 |
3.1.0 | 194 | 3/23/2023 |
3.1.0-preview.9 | 126 | 3/20/2023 |
3.1.0-preview.8 | 132 | 3/18/2023 |
3.1.0-preview.7 | 131 | 3/15/2023 |
3.1.0-preview.6 | 127 | 3/14/2023 |
3.1.0-preview.5 | 129 | 3/11/2023 |
3.1.0-preview.4 | 124 | 3/9/2023 |
3.1.0-preview.3 | 130 | 3/7/2023 |
3.1.0-preview.2 | 128 | 3/4/2023 |
3.1.0-preview.1 | 127 | 3/3/2023 |
3.0.2 | 213 | 3/6/2023 |
3.0.1 | 154 | 3/3/2023 |
3.0.0 | 178 | 2/22/2023 |
2.4.1 | 163 | 2/17/2023 |
2.4.0 | 175 | 2/6/2023 |
2.3.1 | 197 | 1/27/2023 |
2.3.0 | 168 | 1/25/2023 |
2.2.0 | 201 | 12/19/2022 |
2.1.3 | 1,188 | 11/23/2022 |
2.1.2 | 386 | 11/18/2022 |
2.1.1 | 356 | 11/10/2022 |
2.1.0 | 351 | 11/8/2022 |
2.0.3 | 418 | 10/26/2022 |
2.0.2 | 418 | 10/25/2022 |
2.0.1 | 460 | 10/21/2022 |
2.0.0 | 483 | 10/4/2022 |
1.7.3 | 604 | 8/5/2022 |
1.7.2 | 636 | 6/17/2022 |
1.7.1 | 502 | 6/7/2022 |
1.7.0 | 539 | 5/24/2022 |
1.6.0 | 485 | 5/23/2022 |
1.5.0 | 543 | 5/12/2022 |
1.4.1 | 591 | 4/28/2022 |
1.4.0 | 480 | 4/27/2022 |
1.3.1 | 536 | 4/19/2022 |
1.3.0 | 527 | 4/14/2022 |
1.2.0 | 544 | 3/29/2022 |
1.1.3 | 608 | 2/19/2022 |
1.1.2 | 480 | 2/18/2022 |
1.1.1 | 489 | 2/16/2022 |
1.1.0 | 456 | 2/16/2022 |
1.0.8 | 480 | 2/14/2022 |
1.0.7 | 469 | 2/14/2022 |
1.0.6 | 494 | 2/1/2022 |
1.0.5 | 472 | 1/31/2022 |
1.0.4 | 421 | 11/9/2021 |
1.0.3 | 431 | 10/15/2021 |
1.0.2 | 1,027 | 8/16/2021 |
1.0.1 | 460 | 8/13/2021 |
1.0.0 | 400 | 8/12/2021 |
What's new in ver. 1.6.0:
-------------------------
Included a Project Template for creating a Shared Class Library that produces assemblies targeting Xamarin.Forms and .NET MAUI.
With C# Markup, Global usings and Compiler directives, both Xamarin.Forms and .NET MAUI can be targeted from single project.
dotnet new sharedclasslib --name MySharedLib
In which:
*.forms.cs source files will be specific to Xamarin.Forms
*.maui.cs source files will be specific to .NET MAUI
*.shared.cs / *.logic.s will be common to both Xamarin.Forms and .NET MAUI
Refer to VijayAnand.Toolkit.Markup NuGet package source made available here https://github.com/egvijayanand/dotnet-maui-toolkit for a sample.
Join me on Developer Thoughts (https://egvijayanand.in/), an exclusive blog for articles on .NET MAUI and Blazor.