Add `.net6` target framework
See original GitHub issueCurrently it’s not possible to move UI into a separate project (that targets just .net6
) due to MauiToolkint not targeting that framework. In XCT it was possible. Microsoft.Maui.Dependencies
has .net6
, so it’s also possible in vanilla Maui.
Could you please add .net6
and another target framework to Maui toolkit (and Xamarin.CommunityToolkit.MauiCompat
)?
Workardond:
Replace .net6
with net6.0-android30
(and all other frameworks that your app builds for) in all of app’s projects.
Downsides: increases build time, and enables platform specific code in project where there shouldn’t be any.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Target frameworks in SDK-style projects - .NET
NET Standard versions represent standardized sets of APIs across all .NET implementations. For example, a library can target .NET Standard 1.6 ...
Read more >How to target .NET 6.0 with Visual Studio 2019?
Open .csproj file and change <TargetFramework>net50</TargetFramework> to <TargetFramework>net60</TargetFramework> (in some cases it ...
Read more >Visual Studio 2019 Not Showing .NET 6 Framework
To set target .NET runtime version to 6.0, enter <TargetFramework>net6.0</TargetFramework> version in project's .csproj file directly. This will ...
Read more >TargetFramework net6.0 and LangVersion default shouled ...
No. The logic in the MSBuild targets is effectively that if $(LangVersion) is not set then it will be derived from the current...
Read more >Target Multiple Frameworks in .NET Core 2.x App
To target multiple frameworks, change <TargetFramework> to plural <TargetFrameworks> and include monikers for different frameworks you want to target separated ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@brminnick Thanks for approving the PR! Could you please make the same change for
Xamarin.CommunityToolkit.MauiCompat
?the above solution is’nt working for my solution I am adding blazor web assembly reference to .NET Maui Blazor project i have added this
<UseMaui>true</UseMaui>
and added target frameworks for all builds in the Blazor Wasm project , please help with a workaround