You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just found out that actually the Year is supported as native, not extension method. I missed the fact that some were supported as native instead of extension methods. I'll change this issue to actually fix the documentation instead.
daniel-jann
changed the title
Add Year() support (and others that the README says is supported)
Fix example with Year() in README
Jul 7, 2022
@daniel-jann - The example in the docs refers to an Instant which does not have a property called Year and so it is exposed via an extension method. That being said, there’s no way to look at the documentation to know which NodaTime type is being referred to and so the documentation could be improved in this aspect. Maybe a table displaying each supported NodaTime type and whether the part is supported by a native property or an extension method might be a better approach?
The example for the DATEPART Support in the README is using the extension method Year() but this is actually a native Property.
The text was updated successfully, but these errors were encountered: