Add multi-targeting for .NET 8#618
Conversation
|
Hey @jevansaks thanks. I'd be happy with you just adding onto this PR. I'd prefer not just having this without the reason for doing it (supporting Native AOT). I'm not afraid of a significant PR, and I understand this change will be considerable. |
|
|
||
| <PropertyGroup> | ||
| <TargetFrameworks>netcoreapp3.1;net6.0</TargetFrameworks> | ||
| <TargetFrameworks>netcoreapp3.1;net8</TargetFrameworks> |
There was a problem hiding this comment.
I'd actually prefer dropping 3.1 and having the current LTS versions here (6 & 8).
Also, can you update the other test projects, please?
There was a problem hiding this comment.
Sure. So you'd like these projects that were netcoreapp3.1;net6.0 to be net6.0;net8?
There was a problem hiding this comment.
And anything that is netcoreapp3.1 should be net6;net8 too?
There was a problem hiding this comment.
Should only be tests that have .Net Core 3.1, but yes.
There was a problem hiding this comment.
As long as we are continuing to support netstandard2.0 then we should continue to have netcoreapp3.1-based tests so that we can exercise both the reflection-based and JsonTypeInfo-based paths. We can have tests built and run 3x if you want to exercise netcoreapp3.1 and net6 and net8.
|
I'm going to close this and replace with a PR from the |
To enable us to make opportunistic improvements to JsonSchema.NET for .NET 8 customers while keeping support for .NET Standard 2.0, this change adds multi-targeting support to all the projects.
I verified that consuming the new nupkg from a WPF or Net Standard 2.0 project gets the netstandard2.0 dll out of the nupkg, while a NET 8 project picks up the one from the net 8 folder.
Related to #390
Related to #532 (maybe resolves)