This package removes "Only" from DateOnly
/TimeOnly
, which are new structs added in .NET 6.
See: Date, Time, and Time Zone Enhancements in .NET 6 - Why are they named “Only”?
https://www.nuget.org/packages/RemoveOnly/
- This NuGet package contains a Roslyn source generator
- It generates a following C# code in PostInitialization
// <auto-generated />
#if NET6_0_OR_GREATER
global using Date = System.DateOnly;
global using Time = System.TimeOnly;
#endif
- Global using directives have project-wide effects
- All of projects dependent on this package transitively are affected, because NuGet dependency resolution is transitive and this package does not specify
PrivateAssets
property