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
This is a generalization of #185, where it was suggested to use an interface for cds_services. I'd like to suggest to expand this approach and apply it to other types, especially inline defined, too. This allows users to use module augmentation to improve the types in their projects.
// index.d.tsdeclare module '@sap/cds'{exportinterfaceConnect{// limit datasource to services available in the projectto(datasource : 'myServiceA'|'myServiceB',options? : cds_connect_options) : Promise<Service>;}}
The text was updated successfully, but these errors were encountered:
This is a generalization of #185, where it was suggested to use an interface for
cds_services
. I'd like to suggest to expand this approach and apply it to other types, especially inline defined, too. This allows users to use module augmentation to improve the types in their projects.Examples:
Example for possible module augmentation:
The text was updated successfully, but these errors were encountered: