Extension development project template
Overview
This is a project template for the extension development of Next Design. It's very easy to start developing extensions with a project template. The following settings are set in advance in the project template.
- Reference to library package for extension development
- Manifest file
- Basic implementation of extensions
- File copy settings at build time so that extensions can be run
Project templates are available in Visual Studio and the .NET CLI. This template is Published on Nuget.org.
Installation method
The project template will be installed by executing the following from the command prompt (the execution folder can be anywhere). You can also update to a newer version with the following command:
dotnet new --install NextDesign.Extension.ProjectTemplates
Execute the following command for confirmation.
dotnet new
If the installation is completed normally, the following will be displayed.
Templates Short Name Language Tags
-------------------------------------------- ------------------- ---------- ----------------------
Console Application console [C#],F#,VB Common/Console
...
Next Design Extension (Extension Points) ndextp [C#] Next Design
Next Design Extension ndext [C#] Next Design
...
Create a project in Visual Studio
You can create an extension development project from the dialog for creating a new project in Visual Studio.
Once created, you can create a project that includes the manifest file and sample implementation of the extension as shown below.
The following two types of project templates are available.
- Next Design Extension ... Standard extension template.
- Next Design Extension (Extension Points) ... Extension template that makes the definition of extension points very simple.
Attention
The project template is compatible with both Visual Studio 2019 and 2022, but if you have both Visual Studio 2019 and 2022 installed on one machine, only Visual Studio 2022 will show the project template.
Create a project from the command line
You can create an extension project from the command line by running:
dotnet new ndext -n MyExt1
You can also create an extension project using NextDesign.Desktop.ExtensionPoints, which makes it easier to develop extensions.
dotnet new ndextp -n MyExt2
Uninstall
Run the following command to uninstall the project template.
dotnet new --uninstall NextDesign.Extension.ProjectTemplates
troubleshooting
- If you don't see the project template in Visual Studio 2019, make sure the version is 16.8 Prview2 or later and that "Show all .NET Core templates in new project dialog" is checked from the settings below. Please.
See Microsoft Blogs for related articles.