Skip to content

Replace partial variable syntax with fields in MVVM template to support all versions of .NET 8.0 - #6565

Merged
Lauren Ciha (lauren-ciha) merged 3 commits into
mainfrom
user/laurenciha/test-mvvm-on-main
Jun 16, 2026
Merged

Replace partial variable syntax with fields in MVVM template to support all versions of .NET 8.0#6565
Lauren Ciha (lauren-ciha) merged 3 commits into
mainfrom
user/laurenciha/test-mvvm-on-main

Conversation

@lauren-ciha

Copy link
Copy Markdown
Member

This PR replaces the partial variable syntax available in C# 12.0 preview and above with field syntax so that the MVVM C# template is compatible with all versions of .NET 8.0. These changes also introduce a -DotnetSdkVersion parameter to Test-DotnetNewTemplates.ps1 to make testing with multiple .NET versions easier on a local machine. The winui tabview and winui mvvm templates are also added to the test list in Test-DotnetNewTemplates.ps1.

A microsoft employee must use /azp run to validate using the pipelines below.

WARNING:
Comments made by azure-pipelines bot maybe inaccurate.
Please see pipeline link to verify that the build is being ran.

For status checks on the main branch, please use TransportPackage-Foundation-PR
(https://microsoft.visualstudio.com/ProjectReunion/_build?definitionId=81063&_a=summary)
and run the build against your PR branch with the default parameters.

@lauren-ciha

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@lauren-ciha

Copy link
Copy Markdown
Member Author

Dinah Xiaoman G (@DinahK-2SO) Muyuan Li (@MuyuanMS) If you approve the changes, feel free to merge into main or user/laurenciha/default-highest-nuget-version-csharp-templates, whichever you prefer.

@DinahK-2SO

Dinah Xiaoman G (DinahK-2SO) commented Jun 16, 2026

Copy link
Copy Markdown
Contributor

Thanks Lauren Ciha (@lauren-ciha) for fixing the issue and adding the missing test scenarios.

@lauren-ciha
Lauren Ciha (lauren-ciha) merged commit 0481ada into main Jun 16, 2026
50 checks passed
@lauren-ciha
Lauren Ciha (lauren-ciha) deleted the user/laurenciha/test-mvvm-on-main branch June 16, 2026 17:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants