-
Notifications
You must be signed in to change notification settings - Fork 1
Configuration
Stefan Ossendorf edited this page Feb 14, 2024
·
2 revisions
Here you will find all available source generator configuration options and how to use/set them.
csproj property group entries:
- DataPortalExtensionGen_MethodPrefix
- DataPortalExtensionGen_MethodSuffix
As the names suggest these properties add a static prefix or suffix to every generated extension method.
For the csproj property group items it's straight forward:
csproj example:
<Project Sdk="Microsoft.NET.Sdk">
// Other entries necessary
<PropertyGroup>
<DataPortalExtensionGen_MethodPrefix>Prefix</DataPortalExtensionGen_MethodPrefix>
<DataPortalExtensionGen_MethodSuffix>Suffix</DataPortalExtensionGen_MethodSuffix>
</PropertyGroup>
</Project>Generated methods will now look like this:
// See the prefix and suffix around the method Foo
public static Task<YourType> PrefixFooSuffix(this IDataPortal<YourType> portal, ...){}