npm @cap-js/cds-typer 0.20.0
v0.20.0

latest releases: 0.26.0, 0.25.0, 0.24.0...
5 months ago

Added

  • Types for actions and functions now expose a .kind property which holds the string 'function' or 'action' respectively
  • Added the CdsDate, CdsDateTime, CdsTime, CdsTimestamp types, which are each represented as a string.
  • Plural types can now also contain an optional numeric $count property

Changed

  • Empty .actions properties and operations without parameters are now typed as Record<never, never> to make it clear they contain nothing and also to satisfy overzealous linters

Fixed

  • Composition of aspects now properly resolve implicit typeof references in their properties
  • Importing an enum into a service will now generate an alias to the original enum, instead of incorrectly duplicating the definition
  • Returning entities from actions/ functions and using them as parameters will now properly use the singular inflection instead of returning an array thereof
  • Aspects are now consistently named and called in their singular form
  • Only detect inflection clash if singular and plural share the same namespace. This also no longer reports sap.common as erroneous during type creation

Don't miss a new cds-typer release

NewReleases is sending notifications on new releases.